Commit Graph
141473 Commits
Author SHA1 Message Date
Lucas Lefèvre ad8e969323 [FIX] mail: Don't display message if only subtype
Currently, if a message does not have any tracking
value, any attachment and no body BUT has a subtype
with a description, the message is not considered
as empty.

The message subtype should not influence its
"emptyness".
2019-04-17 17:44:08 +02:00
Lucas Lefèvre fbf9b55c5b [IMP] mail: Rename groups field of mail.tracking.value
This commit renames the `groups` field into
`field_groups`.

The previous name was impossible to grep as
the word `groups` is everywhere in the code base.

Also the new name better follows the implicit convention
that fields related to the tracked field all start
with `field_`.
2019-04-17 17:05:17 +02:00
Lucas Lefèvre 8d2d41068d [IMP] mail: Delete tracking values when uninstalling module
Purpose
=======
mail.tracking.values should be deleted when the corresponding
field is deleted (when the module which defined it is uninstalled).

Firstly because we don't want useless data in db.

Secondly because the groups associated with the field can no longer
be checked if it was deleted. As we don't know to whom the value
was restricted, the value should not be displayed anyway.
Note: this case was fixed in saas-12.2 by b9e96b7 but the proper
way to fix it is to delete the tracking values.

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

Delete `mail.tracking.value` when the associated
`ir.model.fields` is deleted.

Two alternatives were considered:

1. Change the `field` field of `mail.tracking.value` from Char
to a m2o to `ir.model.fields` which allows to use delete
oncascade. This implies to modify existing code, but more
importantly it adds database queries.

2. Override the unlink method of `ir.model.fields` to
first unlink associated tracking values.

The first method is probably cleaner but the second method
was nonetheless chosen as we don't want to impact
performance in the main tracking flow only to better
support module uninstalls which happens rarely.

Note: when a module is uninstalled, `ir.model.fields`
are unlinked one by one (in a for loop). Tracking values are
therefore also unlinked field by field. Batchifying field
deletion would greatly reduce the amount of queries.
2019-04-17 17:05:17 +02:00
jbm-odoo 82f33e90d5 [IMP] hr_contract: Improve display of contract related buttons
There is a button on the employee form that show the number of
contracts. This button is only accessible for hr manager,
but not for contract manager.

It's make more sense that this button is accessible for contract
manager. The contract manager can already see all contract from
the menu. Hr manager inherit rights of contract manager.

With this commit, the button is accessible with contract manager
rights and hr manager.

closes odoo/odoo#31415

Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2019-04-17 12:10:22 +00:00
jbm-odoo dbd6fb4e8c [IMP] l10n_be_hr_payroll: manage credit time during contract
In Belgium, we have the concept of time credit and parental leaves.
Globally the person keep full time rights and the initial contract
is always signed on a full time basis. But an avenant with the new
time schedule must be signed.

A new wizard on contract allows to manage credit time. We can
specify the start and stop date, the new calendar and the work
time ratio. The new wage will be computed.

After validation, the current contract will be duplicate two times,
one modified for the time credit contract and the second for after
the time credit period. The current contract will have end date at
the beginnig of the time credit period.

TaskID: 1924200
2019-04-17 12:08:29 +00:00
mgh-odoo 131b5e2519 [REF] mass_mailing: cleanup redundant check in commitChanges()
* Use === for stricter comparison.
* Merge checks on this.wysiwyg and this.mode as they are redundant in
  this case.

Task-ID: 1950784

closes odoo/odoo#32280

Signed-off-by: Pierre Paridans <pparidans@users.noreply.github.com>
2019-04-17 09:30:38 +00:00
mgh-odoo 1f57d4a34c [FIX] web_editor: FieldHtml commitChanges called too soon
The original issue appeared in mass_mailing where triggering the mail
template preview throws a client error.

This commit prevents commitChanges() from being called before the
element is rendered.

Task-ID: 1950784
2019-04-17 09:30:38 +00:00
Florent de Labarre defbb16835 [IMP] product: allow to inherit items search
Create hook method

closes odoo/odoo#32526

Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
2019-04-16 15:56:35 +00:00
Jeremy Kersten 8d64971e99 [FIX] website_sale: some quick fix related to odoo/odoo@1537b475b0
iframe autoclose failed
bad label for
typo

closes odoo/odoo#32740

Signed-off-by: Jérémy Kersten (jke) <jke@openerp.com>
2019-04-16 15:27:32 +00:00
jbm-odoo 59e6611736 [IMP] hr_skills*: Add certification and course in employee profile
When a employee succeed a course or a certification, a new line
will be added in resumé of employee profile.

+ [FIX] hr_skills: remove sequence to sort resumé

Actually, sorting a resumé doesn't work because we add new line for
title in the array.

With this commit, all sequence are removed. The resumé is sorted
by date and skills are sorted by level.

closes odoo/odoo#31764

Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2019-04-16 14:48:25 +00:00
jem-odoo a54d5eede8 [FIX] hr_timesheet: timesheet UoM widget restored
When the assets are loaded, the `hr_timesheet.timesheet_uom` scope is
loaded in order
to bind the `timesheet_uom` to the correct already existing widget (defined
in the session, like `float_time` or `float_factor`, ...).
The problem is that in normal mode (not debug assets), when the binding is
done, the field_registry is empty, so the correct base widget is not applied.

The fix is to add the scope filling the registry in the requirements of the
`timesheet_uom` scope. Strangely, it was working in debug assets mode.

closes odoo/odoo#32736

Signed-off-by: Jérome Maes (jem) <jem@openerp.com>
2019-04-16 09:20:09 +00:00
Romain Derie 0034fd14f1 [FIX] website_sale: flag tests as post_install
Before this commit, runbot-theme was red somehow for the geoip pricelist test.
Adding post_install seems to fix the issue, anyway it is better to flag the
tests as such as it make no sense to test pricelists during module install.

closes odoo/odoo#32727

Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
2019-04-16 13:52:53 +00:00
Rohan Patel 2869750e0f [IMP] website_sale: add new button for buy now on eCommerce
task-1928466

closes odoo/odoo#32440

Signed-off-by: Jérémy Kersten (jke) <jke@openerp.com>
2019-04-16 13:26:11 +00:00
mgh-odoo 208287385e [FIX] base_gengo: private key password field
Before this commit, the gengo private password was displayed in
plaintext in edit mode. This is due to text fields being rendered as
`textarea` in edit mode, which does not support the "password" type.

This commit fixes the issue by turning this field to `Char`, so that
it is rendered as `input` with type "password" in edit mode.

The loss of multi-line from `textarea` is not a big deal, because
gengo passwords are not that long.

Task-ID 1892058

closes odoo/odoo#32725

Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2019-04-16 12:33:45 +00:00
Dharmraj Jhala 1537b475b0 [IMP] website_sale: showcase product videos on eCommerce
This commit adds facility to showcase product videos on it's
eCommerce page. They can be added to 'product.image' model,
same as extra images, thus allowing user to enter multiple
videos per template and per variant. Also, associated image
will be used as a thumbnail for the video on the product's
website page.

task-1945483

closes odoo/odoo#32298

Signed-off-by: Jérémy Kersten (jke) <jke@openerp.com>
2019-04-16 10:34:49 +00:00
Dharmraj Jhala 33e17775e1 [ADD] website: added tools file for utility methods
This commit adds a new file 'tools.py' that can contain
utility methods which can be used at more than one places.

For now it contains a method 'get_video_embed_url', that
will accept a URL for the video and return an iframe snippet
that can be embedded if the provided URL is valid (returns
False otherwise).

task-1945483
2019-04-16 10:34:49 +00:00
Parth Choksi 378d7478b6 [IMP] website: improvements in SEO dialog
In this commit, we have changed behaviour of SEO dialog. Now when you
keep title and description fields empty, then the page will use default
title and description. We have added default_title and default_description
to render the preview with default values when title and description
fields are empty in SEO dialog.

Task ID:1949636

closes odoo/odoo#32449

Signed-off-by: Jérémy Kersten (jke) <jke@openerp.com>
2019-04-05 11:34:19 +00:00
Parth Choksi dc44bf3b6a [FIX] website: allow empty strings in title and meta description
Before this commit, In SEO dialog once you set the title and description,
it was not possible to reset title and description. The reason behind the
issue was, update method was taking title and description from DOM
instead of dialog inputs.

After this commit, you will be able to save empty strings in the title and
description. Once user will do this, the page will use default title.

Task ID:1949636
2019-04-05 11:34:19 +00:00
Parth Choksi 14804b2cd1 [FIX] website: rendering 1 preview instead of 2 in SEO dialog
Before this commit, In dialog box of Optimize SEO, we were getting 2 previews.
This fix will remove the rendering of extra preview.

Task ID:1949636
2019-04-05 11:34:19 +00:00
Priyanka Kakadiya facacc3c19 [IMP] website_sale: make tour tooltip more visible
A tour tooltip was targeting a snippet which is at the bottom of the
page, we now target a snippet which is on top of the list so that the
related tour tooltip is more visible.

task-1942742

closes odoo/odoo#31400

Signed-off-by: Romain Derie (rde) <rde@odoo.com>
2019-04-16 09:10:32 +00:00
Geoffroy Larue 7f0d904d3a [IMP] sale_timesheet: profitability report
In the Project Overview, the Profitability report takes into account
Timesheet costs, but doesn't include information on Revenue.
Because of that, the user is missing crucial information to determine
the profitability of a given project.

This commit aims at fixing this issue by sending the user to the
'Project Costs and Revenues' report of the concerned project when
clicking the 'Profitability' button within the Project Overview page.

Task-1963932

closes odoo/odoo#32554

Signed-off-by: Jérome Maes (jem) <jem@openerp.com>
2019-04-15 09:32:11 +00:00
Geoffroy Larue 637f19e621 [IMP] sale_timesheet: fix typo
Fix a tiny typo in sale_timesheet.

Task-1963932
2019-04-15 09:01:17 +00:00
jpr-odoo 10ce3f7030 [IMP] website: improve UX for logo/font size changing
This removes the 'V' box and it now validates the entered value when the
user clicks outside the box.

task-1952964

closes odoo/odoo#32291

Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
2019-04-16 06:37:48 +00:00
Romain DerieandMitali Patel bc6a680482 [IMP] sale_quotation_builder: uniformize back button
Before this commit, the back button was a small button top right.
But in other modules, the back button is a full width button, like on /my/order
This commit adapt the back button to have the same style by using the adequate
template.

To do so properly, the `o_portal_fullwidth_alert` div was moved from
`portal.portal_layout` to `portal.frontend_layout`.
That way, templates calling `website.layout` can also use it as it inherits
from `portal.frontend_layout`.

task-1943427

closes odoo/odoo#31387

Signed-off-by: Jérémy Kersten (jke) <jke@openerp.com>


Co-authored-by: Mitali Patel <mpa@odoo.com>
Co-authored-by: Romain Derie <rde@odoo.com>
2019-04-11 10:30:09 +00:00
Romain DerieandMitali Patel d3a95ccdea [IMP] sale_quotation_builder: uniformize back button
Before this commit, the back button was a small button top right.
But in other modules, the back button is a full width button, like on /my/order
This commit adapt the back button to have the same style by using the adequate
template.

To do so properly, the `o_portal_fullwidth_alert` div was moved from
`portal.portal_layout` to `portal.frontend_layout`.
That way, templates calling `website.layout` can also use it as it inherits
from `portal.frontend_layout`.

task-1943427

closes odoo/odoo#31387

Signed-off-by: Jérémy Kersten (jke) <jke@openerp.com>


Co-authored-by: Mitali Patel <mpa@odoo.com>
Co-authored-by: Romain Derie <rde@odoo.com>
2019-04-11 10:30:09 +00:00
Swapnesh Shah 634006ad81 [FIX] sale_management: fix field's attribute
on_delete had no effect

closes odoo/odoo#32596

Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
2019-04-15 14:00:22 +00:00
svs-odoo 761cc0d707 [IMP] mrp,stock: more consistent sml button
Set the same icon and title for stock move line buttons and change the
action of the sml button in MRP Unbuild to open stock.move.line model
instead of stock.move model.

Task #1966567

closes odoo/odoo#32570

Signed-off-by: Simon Lejeune (sle) <sle@openerp.com>
2019-04-15 12:06:15 +00:00
mgh-odoo c159735a54 [FIX] pos: Negative payment (refund) on touchscreen
currently, if a user wants to return fund to the customer.
we don't have a button to bill negatively. that will fixed.

Task-ID: 1929650
Closes: #31054

Signed-off-by: Quentin Lejeune (qle) <qle@odoo.com>
2019-04-03 12:13:18 +00:00
qmo-odoo 1d578c2026 [IMP] Project: Add group tasks by create_date
This commit adds the possibility to group tasks by
their creation date

Task: #1959603
PR: #32142

Signed-off-by: Jérome Maes (jem) <jem@openerp.com>
2019-03-27 08:08:41 +00:00
Kaushalya Mandaliya b93ad321fe [IMP] mail: follower name in confirmation dialog on unfollow
Also fixing test so that it uses an existing follower.

Task-ID 1919551

closes odoo/odoo#31139

Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2019-04-15 11:27:02 +00:00
Prakash Prajapati 5a310619cb [IMP] mail: improve document chat window
1. In the systray messaging menu, when hovering on a notification
linked to a document chat, it now shows an "expand" icon. Clicking
on icon opens the corresponding form view with the chatter.

2. Messages in a document chat window no longer show linked document
in their header, as this is redundant with title of chat window.

3. Font size of words "on" and "from" in header of message in chat
windows have been reduced in order to closely match font size of
document link.

Task-ID 1929169

closes odoo/odoo#30957

Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2019-04-15 11:28:03 +00:00
David Beguin aa5faae41c [IMP] mass_mailing : improve heuristics to handle seen mails
Currently the assumption is that if email field doesn't exist on the target
model the mail field has to be email_from. So if one model is targeted and
does not have a field email nor email_from the seen list will raise as it is
searching at least on email_from on the targeted model table.

Better heuristics implemented here is to apply the same rule as
'get email field' from MailThread.message_get_default_recipients§). It
searches for email_normalized (address mixin), email_from, partner_email
and email fields in addition to partner_id which covers all use cases in odoo.

Related to task ID 1907292
Linked to PR #28535

Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2019-04-15 09:25:27 +00:00
Thibault Delavallée 732ec79767 [IMP] link_tracker, mass_mailing: improve link tracker, click and mail statistic views
Purpose is to have more information available in list and form views. As
trying to access those models is a technical move let us give users all
necessary information to understand / debug a bit what happens.

Concerning links we add necessary view type and fields to ease understanding
of tracking data. Notably in mass mailing mailing related information is added
for clicks.

This commit is linked to task ID 1924711 and PR #30059.

Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2019-04-15 09:26:23 +00:00
Christophe Simonis cd4f0d4c11 [FIX] website: activate lang before use
Sane side effect of c7fe955daa do not
blindly set written value to cache.
2019-04-15 11:14:00 +02:00
Christophe Simonis 0a09a4d8a8 [MERGE] forward port branch saas-12.3 up to 120359bf0c 2019-04-12 13:37:44 +02:00
Raphael Collet db97bb7f11 [FIX] *: stupid assignments on non-stored fields without inverse
Some tests had to be adapted because they relied on the buggy behavior:
this was particularly the case when they tried to write on readonly
related fields.

closes odoo/odoo#32460

Signed-off-by: Raphael Collet (rco) <rco@openerp.com>
2019-04-11 14:55:50 +00:00
Sébastien Theys c7fe955daa [FIX] fields: prevent caching wrong value when it's altered by write
Before this commit, the field assignment would cache the value it received, even
if that value was altered during `write`. This can happen if `write` is
overridden (for example to resize images), or it could also happen if a database
procedure is altering the value.

To fix this issue, we do not cache the value that was assigned. This implies
that additional queries may be necessary to retrieve the value, but those were
already necessary most of the time, so it does not have a significant impact on
performances.
2019-04-11 14:55:36 +00:00
Pierre Paridans 1f33ee82d0 [IMP] mail: chat window send message
On a chat window on mobile, the keyboard can be closed by clicking in
the conversation, then there's no way to send your message.

This commit add a "send" icon in the input, after emoji and attachments
icon. Actually the button was already present on mobile but hidden
because of the class o_composer_button_send (used for multiple "send"
buttons). This is fixed by restricting the hidding only to the desired
button.

It also removes an unused 1px top/bottom margin on the thread composer
(wasn't visible as the buttons' background color is the same as their
parent's background).

Finally applying the brand-primary text color on the "send" button only
when not being in a "mini composer" mode instead of globally.

Task ID: 1943863

closes odoo/odoo#32568

Signed-off-by: Adrien Dieudonné (adr) <adr@odoo.com>
2019-04-10 07:38:04 +00:00
Hetal Dhanak 8b7f88edd2 [IMP] stock : Route button on consumable products
-Previously, route state button was visible only on stockable products but now it'll be visible on consumable products too.
This task is related to task id: 1945832

closes odoo/odoo#31623

Signed-off-by: Simon Lejeune (sle) <sle@openerp.com>
2019-04-05 07:02:54 +00:00
Sapan Zaveri 1208d7f839 [IMP] base: contacts email and phone clickable
Purpose of  this task is,
Before this task, the customer was able to click on on the email of a contact from the res.partner view.
But, he wasn't able to click on this same email when the modal of a contact was open.

For the phone it's the opposite. You can't click on the phone from the res.partner view but well from the contact's modal.

So, I made both the fields clickable in both (res.partner view and contact's modal)

Task ID: 1965730
Closes: #32586

Signed-off-by: Jérémy Kersten (jke) <jke@openerp.com>
2019-04-10 13:10:15 +00:00
Mitali Patel b50ffac657 [IMP] sale_management: fill the mandatory field 'applied to' with 'sale order' when create new confirmation email template
Purpose of the task is to fill the mandatory field 'applied to' when create new confirmation email template
from quotation template.

Related Task ID #1934678 closes #31350

Signed-off-by: Jérémy Kersten (jke) <jke@openerp.com>
2019-04-11 05:18:07 +00:00
qsm-odoo 54ae48f2ce [IMP] website: make text snippet's col full width
task-1967273

closes odoo/odoo#32609

Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
2019-04-11 04:50:49 +00:00
Swapnesh Shah f5c6c68165 [FIX] stock: Fix typo on field's attribute
closes odoo/odoo#32562

Signed-off-by: Raphael Collet (rco) <rco@openerp.com>
2019-04-09 20:06:03 +00:00
Kirti Choudhary 0152e95eb3 [IMP] hr_timesheet: hide remaining hours if planned hours not set
If the planned hours are not defined on a project.task, the remaining hours should be hidden.

Task ID - 1930975

closes odoo/odoo#30802

Signed-off-by: Jérome Maes (jem) <jem@openerp.com>
2019-04-10 09:26:29 +00:00
Kazantcev Andrey 6b73d23f7a [IMP] http: code cleaning
reuse current_thread result
No needed to call threading.current_thread() on evry arg setting

closes odoo/odoo#32000

Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
2019-04-10 07:18:59 +00:00
Heckad 1656557e81 [CLA] signature for heckad 2019-04-10 07:16:42 +00:00
Cedric Snauwaert 60dc5df281 [FIX] l10n_be: remove duplicated tax groups
There was one tax group per tax which was strange, so remove all duplicated tax group and only keep one tax group per tax percentage (0%, 6%, 12%, 21%)

closes odoo/odoo#32517

Signed-off-by: Quentin De Paoli (qdp) <qdp@openerp.com>
2019-04-08 13:57:19 +00:00
Suraj Shukla dc2a93792a [IMP] web: properly set margin for the kanban dropdown
While everything looks pretty perfect without this commit,
setting margin on `.dropdown-toggle` and not on its parent
`.o_dropdown_kanban` itself will cause glitches in Studio.

While selecting the dropdown using Studio, the class responsible
for displaying outline (that indicates the selection) is applied
on '.o_dropdown_kanban', which is okay, but the actual child is
positioned using margin, so the outline on parent div looks ugly.

This commit fixes the issue by applying the margin on the proper
selector.

Task 1916583

closes odoo/odoo#30049

Signed-off-by: Martin Geubelle (mge) <mge@openerp.com>
2019-04-09 12:44:01 +00:00
Suraj Shukla 13222fcd68 [IMP] web: better ModelFieldSelector layout
This commit improves the usability of ModelFieldSelector widget
with following points:
- add a placeholder on the input for searching fields
- add more height to the same input for consistency
- properly show 'X' sign within header

Task 1916583
2019-04-09 12:42:40 +00:00
mgh-odoo b993a2d9c8 [IMP] website_sale: restrict deleting/archiving pricelist for ecommerce
Before this commit, if none of the pricelist is available for the website
then frontend ecommerce will crash. This issue is arrived from #30675 PR.
The reason behind crash is, if there is no pricelist associated with
the website then the ecommerce will not get the currency and breaks the
frontend shop.

This commit will restrict user from making those changes which breaks the
frontend shop. We will ensure that atleast one pricelist is available for
each website.

task-1966811
Closes: #32534

Signed-off-by: Jérémy Kersten (jke) <jke@openerp.com>
2019-04-10 06:49:37 +00:00