Commit Graph
141781 Commits
Author SHA1 Message Date
JF Aubert 3fbfbf02ce [FIX] uom: allow ratio change
Allow unit of measure ratio change when there are no product currently reserved
or in stock using this unit of measure.

opw-2455914

closes odoo/odoo#67827

X-original-commit: d78238843ea8933b62d340d1b231a12e94bbf957
Signed-off-by: Arnold Moyaux <amoyaux@users.noreply.github.com>
Signed-off-by: Jean-François Aubert <ajf-odoo@users.noreply.github.com>
2021-03-15 10:22:09 +00:00
Nicolas Lempereur 26b29de7d2 [FIX] web_editor: no quick edit on html link click
When clicking on link in html fields, we do not wish to start quick
edition. With this change this is excluded.

closes #68023

closes odoo/odoo#68212

X-original-commit: ecbdddbf0cff0964b44e7f0571d372ccbd051a72
Related: odoo/enterprise#17235
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
2021-03-22 16:59:38 +00:00
Nicolas Lempereur 0e004e1b7c [FIX] web: no quick edit on mouse text selection
Do not trigger quick edit when we are selection text with mouse:

- click and holding to select text
- multiple clicks selecting text

Since click on an editable field now change the edit mode, we could no
longer select the text.

With this change, quick edit is delayed by a given delay and if the edit
mode is not enabled if:

- there is a subsequent click within the delay
- there is a text selection when the click event is handled

closes #68023

X-original-commit: 2939ea4dd4736e659cc3e4df2226a3b08ac8ec48
2021-03-22 16:59:38 +00:00
Tiffany Chang (tic) 0de75b228a [FIX] stock: remove broken doc link
Remove obsolete quality documentation link (added after v14, hence 2
separate PRs).

Related PR: odoo/odoo#68135

closes odoo/odoo#68228

Task: 2457087
X-original-commit: 0994751d2966c9284341f96b7924b7fa9848d282
Signed-off-by: William Henrotin <Whenrow@users.noreply.github.com>
Signed-off-by: Tiffany Chang <ticodoo@users.noreply.github.com>
2021-03-23 10:17:02 +00:00
Alexandre Kühn f5acf714b0 [FIX] mail: no traceback on uploading attachment
Task-2486731

closes odoo/odoo#68431

X-original-commit: fb713f58b20835bd9bc5257f87817628ff1cf69a
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2021-03-26 22:17:10 +00:00
Dhruv Patel 0faeb2b769 [FIX] mail: chatter autoloading loads more messages too quickly
if you check on any chatter with a lot of messages, you will see that it starts
loading all the messages as soon as you scroll down even just 1 pixel.
This makes a lot of loading of the messages for no reason unnecessarily.
What should happen instead is that it should load more message only when
scrolling all the way down to the bottom.This works fine in chatwindow & discuss.

With this commit, resolved this issue by providing the exact scrollable element
to the message list from parent component to the child. so with proper element
we can have proper scrollable heights and other dimensions as well to handle
load more messages properly.

Task : 2382735

closes odoo/odoo#68430

X-original-commit: 63b15e23d95b310a12bdbc30c983081ed84187a3
Related: odoo/enterprise#17335
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2021-03-26 20:34:16 +00:00
Odoo's Mergebot a86382ffa2 [IMP] website, website_sale: support recently viewed in product snippet
Before this commit the recently viewed products were handled differently
from the dynamic product snippet.

After this commit the dynamic product snippet supports the functionality
of the recently viewed products snippet:
- its template used to show each product
- its filter of displayed products
- its "Add to cart" feature (with the animation)
- its "Forget" feature (only applicable when viewing recently viewed)
Also added "Accessories" and "Recently Sold With" filterings.

Several kinds of filtering can be combined.
- Products can be restricted to a given category
  - Pseudo categories for all products or current category can be used
- Products can be restricted to matching names
- Products can be obtained from one of the following:
  - Newest
  - Latest sold: ordered by descending frequency in last 8 orders
  - Latest viewed
  - Accessories (of the current product)
  - Recently sold with (the current product)
Accessories and recently sold with are only available in product pages.

Also, generic templates have been considered useless and the whole
mechanism allowing them has been removed (this includes the
pre-rendering mechanism for the fields specified in the filter).

task-2453416
See https://github.com/odoo/upgrade/pull/2153

Description of the issue/feature this PR addresses:

Current behavior before PR:

Desired behavior after PR is merged:

--
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr

closes odoo/odoo#65554

Related: odoo/upgrade#2153
Signed-off-by: Jérémy Kersten (jke) <jke@openerp.com>
2021-03-26 23:34:42 +01:00
Priyanka Kakadiya fc34260bee [FIX] mail: command suggestion should only show if '/' is first char
PURPOSE:

command suggestion should only open if command is the first char.

SPECIFICATION:

command suggestion should only open if command is the first char.

Task-2487518

closes odoo/odoo#68428

X-original-commit: 2208a9b5e18881f5fbfea56872990daafba45579
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2021-03-26 19:52:37 +00:00
Xavier Dubuc 49663be314 [FIX] mail: fix attachment preview for previewable files
task-2412150

closes odoo/odoo#68427

X-original-commit: 2e1bcb079ec361d85a80d790b8a2cc395055f09a
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2021-03-26 19:51:11 +00:00
Priyanka Kakadiya 725a1b674d [FIX] mail: do not show typing when using a / command
PURPOSE:

Currently typing status is sent when typing a command.

SPECIFICATION:

Typing status should not be sent when typing a command.

Task-2363267

closes odoo/odoo#68424

X-original-commit: 7f28e68776849993f16b4b27e6213c0cce67de37
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2021-03-26 19:04:07 +00:00
Benoit Socias 3355dc1623 [REF] website, website_sale: support recently viewed in product snippet
Before this commit the recently viewed products were handled differently
from the dynamic product snippet.

After this commit the dynamic product snippet supports the functionality
of the recently viewed products snippet:
- its template used to show each product
- its filter of displayed products
- its "Add to cart" feature (with the animation)
- its "Forget" feature (only applicable when viewing recently viewed)
Also added "Accessories" and "Recently Sold With" filterings.

Several kinds of filtering can be combined.
- Products can be restricted to a given category
  - Pseudo categories for all products or current category can be used
- Products can be restricted to matching names
- Products can be obtained from one of the following:
  - Newest
  - Latest sold: ordered by descending frequency in last 8 orders
  - Latest viewed
  - Accessories (of the current product)
  - Recently sold with (the current product)
Accessories and recently sold with are only available in product pages.

Also, generic templates have been considered useless and the whole
mechanism allowing them has been removed (this includes the
pre-rendering mechanism for the fields specified in the filter).

task-2453416
https://github.com/odoo/odoo/pull/65554
2021-03-26 15:41:44 +00:00
Benoit Socias 429f9b70af [IMP] website, website_sale: remove recently viewed products
Before this commit recently viewed products included below the single
product details were a specific snippet.

After this commit recently viewed products has been removed and
cross-product drop areas have been added to the product page.

task-2453416
https://github.com/odoo/odoo/pull/65554
See https://github.com/odoo/upgrade/pull/2153
2021-03-26 15:41:13 +00:00
Nicolas Lempereur 8a5d22826c [FIX] website_forum: show normal image modal in forum
In #67893 the image icon was removed, but it contradicts the interface
and made a feature that was working for employee less available.

Since saas-12.3, we always use the full media dialog when showing the
editor on the forum so we could not add an image with the image icon if
were not an employee.

Before saas-12.3, the original summernote image dialog was shown for
everyone but website editor that saw the full media dialog (beecause we
are using the same editor to do both things).

With this change, we always have the original dialog in the forum
message editor thanks to a new option "disableFullMediaDialog".

opw-2470720

closes odoo/odoo#68166

X-original-commit: c026c360fb77ce43f47f7645f48e37bced988b85
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
2021-03-19 18:30:00 +00:00
Ipsita Borisagar 5c4133f074 [IMP] mail: display subject in chatter
PURPOSE

Currently subject of message is visible in Discuss' Inbox and mailing channels,
need to add subject into chatter and non mailing channels.

SPECIFICATION

Adding subject into the message in chatter and non mailing channels.

LINKS

PR https://github.com/odoo/odoo/pull/61570
Task-2156170

closes odoo/odoo#61570

Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2021-03-23 10:11:37 +00:00
Julien Castiaux 7a235c19ff [IMP] core: Deprecate cr.autocommit(True)
Since Odoo 13.0 and the refactor of the internal synchronisation between
the cache and the database, it is unsafe to use the ORM with the cursor
in autocommit mode. The function is deprecated for removal in the
future.

closes odoo/odoo#68313

Task: 2442905
Signed-off-by: Raphael Collet (rco) <rco@openerp.com>
2021-03-26 16:10:12 +00:00
Adrien Dieudonne 19f21e364e [FIX] hr_skills: Employee resume alignment on mobile
Before this commit, you had to scroll horizontally to see
some options like "add" and "delete" in the "resumé" tab.
It's because long titles aren't break to the next line.

.o_resume_line_title had "white-space: nowrap" property because
of list view global rules.

Steps to reproduce:
- Go to "Employee"
- Select "Mitchell Admin"
- See "Université Libre de Bruxelles - Polytechnique" as title

closes odoo/odoo#68385

Task-id: 1929043
X-original-commit: ca0d8978b6585fe4f96100df56b8a7346468dc6c
Signed-off-by: Pierre Paridans <pparidans@users.noreply.github.com>
Signed-off-by: Adrien Dieudonné (adr) <adr@odoo.com>
2021-03-26 12:10:09 +00:00
Romain Derie 7cdf04df67 [IMP] website: add qweb view to see view hierarchy
The core website behavior is the COW (copy on write) which makes it possible to
handle multiple websites on a single database.

When you do a CRUD operation on an `ir.ui.view` in a website context, the ORM
normal behavior is bypass to perform special stuff, such as:
  - Write: if the view is generic (no `website_id`), we bifurcate the write on
           the specific view (same `key` but with `website_id` set). If that
           view doesn't exist, we create it and fork its whole descending
           hierarchy. This write behavior is known as COW.
  - Create: we ensure that view is created only for the website and no other.
            Basically we just add a `website_id` to that view, but it might
            also be about setting the correct `inherit_id` by finding the
            specific view among multiple views with the same `key`.
  - Unlink: if the view is generic, we will unlink that view but also create a
            copy of that view for every other websites so they remain
            unmodified: this is known as COU (copy on unlink).

All those behavior aims to satisfy to the multi website holy grail:
 -- Any modification in a website context should never impact another website --

Because of those uncommon behaviors, it is sometimes hard to understand or
investigate a database, as views might be copied, up to the point where there
is multiple whole view hierarchies.

This commit attempts to create an user interface to easily figure what's going
on in a database at an `ir.ui.view` level.
The mains advantages of that new `ir.ui.view` Qweb view is to:
  - easily figure which views are COW'd on which website
  - easily detect which views have a real `arch` modification
  - easily see that `arch` change

Closes #63040

Signed-off-by: Jérémy Kersten (jke) <jke@openerp.com>
2021-03-26 15:29:42 +00:00
Romain Derie 905c9b52a7 [IMP] base: add filter on ir.ui.view to filter modified views
Closes #63040
2021-03-26 13:52:02 +00:00
Romain Derie fd0538c5b8 [IMP] website: clean website views file
Regroup, reorder and section comment

Closes #63040
2021-03-26 13:52:02 +00:00
Olivier Dony 9427804ef4 [FIX] ir.cron: execute jobs in priority order (again)
The selection mechanism selects 1 job at a time from the jobs that are
ready to execute, but while doing this it should respect the `priority`
defined on the jobs. Otherwise the field is useless, and the user has no
way to ensure that a long-running job does not cause starvation.
(Assuming execution resources that are insufficient for 100% of the
processing to happen)

The `priority` ordering was apparently lost during the introduction of
the trigger mechanism in #62124 via
4b28f1162a.
It was previously taken into account in `_process_jobs()`.

The `ORDER BY` is not strictly necessary in `_get_all_ready_jobs()`, but
it seems more consistent for this method to return an ordered list as
well, given the semantics of the `priority` field. We don't know what
the caller will do with the result.

closes odoo/odoo#68411

X-original-commit: 9d570662b4016b5cd9ad3c85abbcb5428c169cc6
Signed-off-by: Olivier Dony (odo) <odo@openerp.com>
2021-03-26 15:04:23 +00:00
Laurent Stukkens (LTU) 0b2a06d81c [FIX] pad_project: fix project view
Prior to this commit the install of pad_project crashed because it
tries to add a the description_pad field bellow the description field in
the project form view, which was part of the description notebook that
has beeen removed in #66589.

After this commit the description_pad will not more be added in the project view.

Deletion of the fields in the model will be assessed with the PO.

closes odoo/odoo#68410

Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2021-03-26 15:04:41 +00:00
Josse Colpaert ca4a25d884 [FIX] l10n_latam_invoice_document: only trigger constraint when partner_id is set
Before, when importing twice the same invoice, or even with the more
theoretical possibility of having the same number for different partners,
the constraint would be triggered, giving unnecessary problems when
importing vendor bills with an uncertain partner_id.

If we check the logic followed in the regular accounting on the ref field,
it only triggers when a partner is set, so we can follow the same logic here.

closes odoo/odoo#68408

X-original-commit: 9cbf63bd644d6d6d629266fe31edc91b44f22aa6
Signed-off-by: William André (wan) <wan@odoo.com>
Signed-off-by: Josse Colpaert <jco@openerp.com>
2021-03-26 14:39:01 +00:00
Thibault Libioulle 8bbf0e9e64 [IMP] project*: improve sub tasks workflow
We want to ease user experience regarding sub task creation and
management. We thus enforce the values of subtask stage, project and
parent task. we want to remove the ability of a user to choose a
third-party subtask project different than the actual one. Also, we want
to remove the ability to make one sub task recurrent. In general, We
want to improve and strengthen the relation parent-childs for Tasks. A
sub task is dependant of its parent all along the workflow.

This commit address those needs and, especially, removes the subtask
project configuration discussed in :
- odoo/odoo@66a0e5a
- odoo/odoo@b709e22

1) With this commit we want to change the way to link a subtask with its
project	for UI reasons, we want to be able to easily distinguish
subtasks that are linked to the project of their parent from subtasks
that are linked to another project. To do so, the idea is to create a
field display_project_id not required. Only relevant tasks are linked
to their project through this display_project_id, the other are linked
to their project only via project_id. As a result, domains in the
application are only based on the fact that tasks have
display_project_id. The other are simply hidden.

2) The number of subtasks is shown on kanban and list views with a
   wigdet to easily render it and extend the UI.

3) The default sub-task assignee is the assignee of the parent task.

4) Task form is modified to integrate those changes.

5) Various searches on project task are restricted with a clause where
display_project_id must be not null. Except in portal, in which context
we always display all tasks and subtasks.

PR community: #62577
PR enterprise: odoo/enterprise#15043
PR upgrade: odoo/upgrade#1984

task-2388034

Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2021-03-26 13:51:39 +00:00
Adrien Widart 642f72bfcc [FIX] microsoft_calendar: warn user if attendee without email
When syncing both Odoo and Outlook Calendar, if one Odoo event has an
attendee who does not have any email adress, it will lead to a traceback
error.

To reproduce the error:
1. Create a partner P who does not have an email address
2. In Calendar, create an event E with P
3. Sync with Outlook

Error: An Odoo Error is raised. When syncing from Outlook to Odoo, it
also sync the E-event (in case the latter has been updated on Outlook).
The Microsoft2Odoo syncing uses the email address of each attendee.
Since P does not have any, this creates the error.

Although Odoo allows the use of participants without email, this is not
the case for Outlook. On Outlook Calendar, as soon as a user adds an
attendee to an Event, Outlook will want to send an invitation before
saving this event (so, if the participant does not have any email
address, it won't be possible to save the event).

When syncing, the E-event will be added to Outlook Calendar. However,
for the same reasons as in the previous paragraph, it will not be
possible to update this event from Outlook Calendar.

Therefore, the solution is to prevent the user from having attendees
without email when his calendar is synchronized with Outlook.

OPW-2439027

closes odoo/odoo#68407

X-original-commit: dbb65f3abfbc7d6e3d8167839659eac79b1e6b31
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
Signed-off-by: Adrien Widart <adwid@users.noreply.github.com>
2021-03-26 14:13:15 +00:00
Nasreddin (bon) 2ebb327a9a [FIX] sale: allow select any product combination
Issue

	- Install 'Sale', 'Inventory' and
	  'Sale Product Configurator' module
	- Create a product X with the following attributes:
	  attr1 : val1, val2
	  attr2 : val3, val4
	- Click on 'Configure Variant'
	- Select val3 and add exclude for val1
	- Select val4 and add exclude for val2
	- Go to 'Sales' and create a 'Sale Order'
	- Select product X (a wizard should open)

	Can't change option combinaison.

Cause

	Options combinaison (that are not allowed) are disabled.
	This commit introduce the error:
	https://github.com/odoo/odoo/commit/6150311b72089e3fbae6bc27551bc7f4792e68dd

Solution

	revert commit.

opw-2478854

closes odoo/odoo#68401

X-original-commit: 0a92706cd0d38d33a399bec7b5b5fbe7ab7f8576
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
Signed-off-by: bon-odoo <nboulif@users.noreply.github.com>
2021-03-26 13:36:07 +00:00
yograj tandelandMohammed Shekha ef62df2bfd [IMP] web: consider FieldDependencies given on custom widget
With this commit we support adding FieldDependencies on custom widget, consider
FieldDependencies given on custom widget and add it to fieldInfo so that when
modal does calls to server to fetch data it consider those fields while reading

this will let us to design custom widget which may have some other fields in
dependency, say for example weekly recurrence widget which uses sun, mon etc.
fields, so with this we can fetch data of those dependent fields without adding
it to view.

task-2335399

closes odoo/odoo#60277

Related: odoo/upgrade#2021
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
Co-authored-by: Mohammed Shekha <msh@odoo.com>
2021-03-26 12:25:44 +00:00
YOGRAJ TANDELandMohammed Shekha 7da9c296eb [ADD] calendar,lunch,web: weekly recurrent widget
with this commit we adding weekly recurrent widget, currently proeject and
calendar shows boolean for each day vertically but with this widget we displays
week days and its boolean horizontally.

Here widget will display first day as per language's week_start field, also we
adds FieldDependencies on custom widget and consider those FieldDependencies
while processing view node in basic_view.js

We add support of registry to contain owl custom widgets and add support
of rendering owl custom widgets.

Also with this commit we removes fields like sun, mon, tue etc. from view and
instead use "web_weekly_recurrence" custom widget to display boolean for each
week day.

Co-authored-by: Mohammed Shekha <msh@odoo.com>
2021-03-26 12:25:44 +00:00
Mohammed ShekhaandAaron Bohy 877ef5552b [IMP] web: add support of owl custom widget
add support of <widget> tag for owl, In order to prepare the future,
we want to convert everything in Owl, in future widgets generated by
<widget> tag will also be converted to owl.

with this commit we support widget to instantiate using ComponentWrapper.

task-2337692

Co-authored-by: Aaron Bohy <aab@odoo.com>
2021-03-26 12:25:44 +00:00
YOGRAJ TANDELandMohammed Shekha 7fb9c81296 [IMP] calendar,lunch: change field names
with this commit we changes field names for week days like su, mo, tu etc. to
sun, mon, tue and so on in calendar module, this is going to be used in
task 2317795 where we developed recurrency module for recurrency mixin.

Also with this commit we change field names of weekdays in lunch module to have
same name as we have in calendar and project module so that we can easily use
custom widget "web_weekly_recurrence" instead of defining boolean field in xml
for each day.

task-2335399

Co-authored-by: Mohammed Shekha <msh@odoo.com>
2021-03-26 12:25:44 +00:00
Simon Genin (ges) 3d0b77a711 [FIX] web: remove memory leak in editable list used as one2many
The confirmUpdate method in list_editable_renderer would destroy all
rows' widgets and recreate them *except* the currently modified one
(this one gets updated).

The problem was that the widgets of the current row were recreated
anyway. It created a memory leak.

This memory leak isn't such a big deal, as anything is garbage
collected as soon as the view is left anyway (so it's a small leak
during the lifetime of the x2many list)

The fix consists in keeping the reference of the widgets on the
currently modified row, and when all rows' widgets are recreated, we
delete a replace by our reference for the current row.

closes odoo/odoo#68386

Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
2021-03-26 13:27:48 +00:00
Simon Genin (ges) a52d32822d [FIX] web: o2m list editable updates did not call on_attach_callback
In a list editable used as a one2many representation, inside the
confirmUpdate method, the on_attach_callback method on the field widgets
wasn't called.

It wasn't detected earlier because most of the legacy widgets didn't
implement this callback (all owl components do however).

It was problematic as the confirmUpdate function destroys and recreates
all the field widgets (with exception for the currently modified row).
Not calling the on_attach_callback would result in missing / unexpected
behavior such as _applyDecoration not being called.

The fix is simple: call the method if it exists on all the widgets after
they have been created.
2021-03-26 13:27:17 +00:00
Sébastien Mottet (oms) 2323af4451 [REF] website, *: centralize color palettes in website
*: web_editor

All theme specific color palettes have been moved into website.
It allows to access them without having to install theme modules and
this is a preparation for our website configuration screen task.

Lists of palettes have been replaced by maps with palette names as keys.
Those names are composed of the palette's original theme name ('generic'
or 'base' for palettes not specific to a theme) and of an index
(ex: 'anelusia-2'), for compatibility.
To keep compatibility with previous version we also convert old color
palettes number to color palette name, specifically for each theme.

A side effect of this change is that we got rid of all gray palettes
which existed in some themes. Those were not fitting the new possibility
of gray customization in the third panel and were not always really a
good customization of the default grays (they still were there mainly
for historical purposes). Unfortunately, this may have some side effect
for old websites which used those grays but the new gray palettes (left
to the default one) should most of the time come as an improvement of
the old ones, and they are now customizable by the user. In the future,
we may associate a perfectly-chosen default gray palette, fitting the
customization system, for each color palette.

PR: https://github.com/odoo/odoo/pull/67488
task-2451965

closes odoo/odoo#67488

Related: odoo/design-themes#455
Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
2021-03-26 11:31:17 +00:00
qsm-odoo e08184103c [IMP] website: add technical improvement for gray customization
Improvement of [1]. Allows to not have to save the gray-hue and
gray-extra-saturation server-side at all, and thus better allow to use
a fully customized gray palette in theme should a theme need it.

[1]: https://github.com/odoo/odoo/commit/35d27a6c1d3dab621de7f059565d7619ae004412

Merged with https://github.com/odoo/odoo/pull/67488
2021-03-26 11:31:17 +00:00
Chong Wang (cwg) cb8dba7efb [IMP] sale_subscription: support UTM
Propagate UTM from SO to subscriptions

closes odoo/odoo#67554

Taskid: 2457461
Related: odoo/enterprise#16349
Related: odoo/upgrade#2220
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2021-03-26 12:18:28 +00:00
honey patel 5e2b103cf0 [FIX] hr,(_contract): fix small issue of groupby dropdown
Currently, groupby and filter dropdown are not working properly
on employee kanban card because when dropdown is exact on position of
fixed-bottom it will direcly click on the kanban card instead of the
custom groupby dropdown due to higher z-index of the fixed-bottom then
dropdown-menu. also chat icon in fixed-bottom is overlap on zoomed
image as zoomodoo-flyout has z-index 100.

fixed-bottom has z-index 1030 while drodown has z-index 1000 so instead
of clicking on dropdown it was going to click on kanbancard bottom.

So in this commit, improve the behaviour and decrease the z-index of
fixed-bottom to allow the click on custom groupby dropdown and hide
the chat icon behind the zoomed image.

Also when try to create contract, employee field does not show proper.
so moved it before start date with label.

closes odoo/odoo#66788

Taskid: 2452363
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2021-03-10 05:14:48 +00:00
Bruno Zanotti (ADHOC) 2d0034689c [IMP] l10n_ar: original amount in VAT Book
Since AFIP requires to keep the original amounts in the txt files
for the digital VAT Book, we deprecate the option
'company_currency = True' in the methods used to prepare the data.

closes odoo/odoo#67927

Signed-off-by: Josse Colpaert <jco@openerp.com>
2021-03-16 11:06:11 +00:00
Odoo's Mergebot c975d128cc [MERGE] project: add task dependencies feature
Purpose
======

Sometimes, a task can only be completed once another is (e.g. 'install boiler' can only be done once 'order boiler' is complete). Communicating this information is key to organize a project and for the users to know on what they can start working when.

## Settings in Project App

- Add a 'Task Dependencies' setting under the 'Tasks Management' section
- Add the same setting on the project form view.
- As for the sub-tasks feature, enabling this feature in the settings of the app, should enable it on all existing and newly created projects with is_fsm = false.

## Task form view

- Add a 'Blocked by' notebook.
- In this notebook:
    - add new many2many field called *depend_on_ids* containing the tasks in which the current task depends on these tasks with the following fields displayed by default: name, user_id, date_deadline, stage_id.
    - add a 'view task' button on each line that should open the corresponding form view.
- Filter task list for depend_on_ids Many2many field.
- Check no cyclic task dependencies.

task-2387984

--
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr

closes odoo/odoo#66740

Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2021-03-26 11:08:10 +01:00
Tiffany Chang (tic) 17a8258a95 [FIX] mrp, purchase, (sale_)stock: remove/update dead links
Some documentation was removed to reduce technical debt + they deemed
were self-explainatory. The links to these pages are removed to match.

Some links were also updated/changed to redirect => these links have
been updated to match the new addresses.

closes odoo/odoo#68214

Task: 2457087
X-original-commit: 49cfc4165ff19f6fd293bed2f6867a32cc0b8c5d
Signed-off-by: William Henrotin <Whenrow@users.noreply.github.com>
2021-03-22 17:33:30 +00:00
nie 9588881b0e [FIX] sale_coupon: translate email subject and template
Steps:
- Install Sales
- Go to Settings / Translations / Languages
- Install Dutch
- Go to Settings / Users & Companies / Users
- Change demo's language to Dutch
- Go to Sales / Configuration / Settings
- Activate Coupons & Promotions
- Go to Sales / Products / Coupon Programs
- Create a new Coupon Program
- Click Generate Coupon
  - Generation Type: Number of Selected Customers
  - Matching rule: Name contains demo
- Generate
- Go to Settings / Technical / Email / Emails
- Open the email you just sent

Bug:
Parts of the email are not translated

Explanation:
The `lang` field is used to determine the template's language. Coupon
emails where missing one.
Also, the subject of the email wasn't translated.

opw:2467640

closes odoo/odoo#68366

X-original-commit: cb57e5dd9d850820f715b5ce4048c81f96b028b1
Signed-off-by: backspac <backspac@users.noreply.github.com>
2021-03-25 17:41:40 +00:00
Adrien Widart 212deeea29 [FIX] mrp: prevent creation of reordering rule on kit
Because kits might never be in stock, it's impossible to fullfil the
quantity of a reordering rule: asking a mini/maxi quantity on a kit
makes no sense.

Odoo will continuously propose to order more to reach the quantity
necessary for the kit, but will never reach the asked qty, as it's a
kit, not a manufactured product.

OPW-2448878

closes odoo/odoo#68362

X-original-commit: c47a9319c081105e46e56f881b25fd6442266089
Signed-off-by: Adrien Widart <adwid@users.noreply.github.com>
2021-03-25 16:50:54 +00:00
Anh Thao Pham (pta) cb0791d948 [FIX] point_of_sale: fix customer search when a field contains line break
- Install contacts & point_of_sale
- Go to Contacts and import a contact from an Excel file with the following data:
  /!\ The street field should contain a line break /!\

  Name | Phone  | Street
  -------------------------
  Test | 123456 | Multiline
                  Street

- Open a POS session
- Go to Customer selection page
- Search for "123456"
The imported res.partner will not be found by his phone.

A partner search in POS is working with a regex search on a string containing all partners.
This string is supposed to contain 1 line for each partner and a line is formatted as followed:

  id:name|barcode|address|phone|mobile|email|vat

However, in this case, partner's address contains a line break, resulting on a line like this:

  id:name|barcode|address (part before line break)
  address (part after line break)|phone|mobile|email|vat

This partner is defined in 2 lines and all data from the second line cannot be matched with regex.

opw-2477994

closes odoo/odoo#68365

X-original-commit: 3de16a7a4616c73cfabd64aa010801f687cf14af
Signed-off-by: pimodoo <pimodoo@users.noreply.github.com>
Signed-off-by: Anh Thao PHAM <kitan191@users.noreply.github.com>
2021-03-25 17:19:22 +00:00
Swapnesh Shah af0001062f [IMP] sale: Deposit Product should be service
Before this commit, Creating new `Deposit Product` from Settings was not setting type to `Service` while we have the domain to display on Service products here.

Now, we added the Default type in context.

closes odoo/odoo#68364

X-original-commit: 7e8019be992a7919ca94ad7cf6c1e83156812b1c
Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
2021-03-25 17:08:40 +00:00
Benoit Socias 20433b9796 [IMP] website: make maps available without configuration
Before this commit displaying a map on the website required the use of
the Google Maps snippet which requires to configure an API key.

After this commit displaying a map on the website can also be done with
a simpler Maps snippet which requires no configuration.

task-2464422

closes odoo/odoo#66766

Signed-off-by: Jérémy Kersten (jke) <jke@openerp.com>
2021-03-25 15:43:21 +00:00
Barad Mahendra 9a57330d06 [IMP] web: display the default label next to the icon in state_selection
Purpose of the commit is to display the default label next to the icon
for state_selection widget in list view.
also that widget support the hide_label option to hide the label in
state_selection widget of the list view.

Related Ent PR: odoo/enterprise#16559

closes odoo/odoo#66589

Taskid: 2451287
Related: odoo/upgrade#2195
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2021-03-22 08:42:04 +00:00
Barad Mahendra a6ae6d8217 [IMP] project,web: generic improvement for project revamp
Purpose of the commit is to do the generic improvement for the
refactoring of project.

So in this commit, done the following changes:
 - move the date_deadline and the tag_ids field to the right column
 - remove the warning 'by saving this change, the customer email and phone
number will also be updated.'
 - track the priority field on task
 - move the deadline field above the fa-star and fa-clock-o icons
 - the name of archived tasks should be crossed out
 - project form add a 'deadline' field below the user_id one
 - project form remove the 'description' notebook
 - remove the 'project' field from the quickcreate of task.

Related Ent PR: odoo/enterprise#16559
TaskID: 2451287
2021-03-22 08:41:04 +00:00
Odoo's Mergebot 2133b807a8 [MERGE] sale_timesheet: employee rate for fsm projects
Purpose
======

Currently, the user can configure his field service project to be billed at an employee rate but it just won't work. The rates configured for each employee on the project are not taken into account when the task is marked as done. As a consequence, the only workaround to support this kind of use-case is to create 1 task per employee with a different rate (or to add service products on the task). Those solutions are far from being ideal. We should give more flexibility.

## Details

To reach the goal, some updates are made:
 - Move the timesheet_product field in employee mappings into the fsm sale module, because this field is only used for fsm projects,
 - render _timesheet_determine_sale_line no static to easily override it,
 - fix bug when the user change project on task form view, the project for non billed timesheets is not correctly changed,
 - let the SOL in task when the user wants to change the project of it to a project with pricing type defined as employee rate. Before when the pricing type of the destination project is employee rate, we remove the SOL of the task.

task-2376382

--
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr

closes odoo/odoo#66157

Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2021-03-25 19:34:16 +01:00
bat-odoo feca3ad527 [IMP] base: update l10n icons
Purpose of the task is to update all l10n modules icon with new icon that i have
found in task attachment.

So in this commit, Updated all l10n modules icon with new icon.

closes odoo/odoo#65329

Taskid: 2442631
Related: odoo/enterprise#16054
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2021-03-25 15:01:43 +00:00
nounoubensebia 417622d655 [IMP] [website_]event[_questions|_sale] datetimes sales start/end
changed the start/end date fields to datetime fields, in order to allow more
flexibility for the user and enable them to set a precise point in time at
which ticket sales should start/end, because otherwise ticket sales/end would
always be set at midnight which is not very flexible.

Task-2431440

closes odoo/odoo#65133

Related: odoo/upgrade#2126
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2021-03-25 14:58:20 +00:00
Urvi Soni e109e476e6 [IMP] various: reorganize the general setting
Purpose of the task is, 'general setting' is not easily understandable
by the user. The user often gets lost. This is especially damaging
through onboarding as some new users like to discover the software by
scrolling through the general settings.

So in this commit, the general setting is well organized and easily
understandable by the user.

Related PR: https://github.com/odoo/enterprise/pull/14707

closes odoo/odoo#61645

Taskid: 2374990
Related: odoo/enterprise#14707
Related: odoo/upgrade#1958
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2021-03-25 15:48:10 +00:00
Yannick Tivisse 8444643cc6 [FIX] hr_contract: Allow manager to modify current employee contract
closes odoo/odoo#68259

X-original-commit: c60672e123e996a82a706a8aed5456ddd2288578
Related: odoo/enterprise#17259
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2021-03-25 10:24:19 +00:00