Commit Graph
137228 Commits
Author SHA1 Message Date
Sébastien Theys 6b06ada2c2 [FIX] mail: fix messaging locale update on translation bundle change
closes odoo/odoo#55167

X-original-commit: c3eb3f04e06cea84dd98323b6d10867dead5b953
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2020-07-29 15:41:10 +00:00
Xavier Dubuc a28f24ca3f [FIX] mail: prevent attachment delete from not authored message
task-2299330

closes odoo/odoo#55164

X-original-commit: c331b6761fbc1e8dd4d554109acab142ab02702d
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2020-07-29 15:39:56 +00:00
Xavier Dubuc 69d89218f9 [FIX] mail: fix read more/less span insertion
task-2248307

closes odoo/odoo#55163

X-original-commit: a8ea9bc98d114eef056babc0d2639eaddbcf3778
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2020-07-29 15:39:31 +00:00
Victor Feyens 42fc0f4910 [FIX] product_matrix: matrix edition on a new record.
Probably since recent js framework changes, when trying
to modify the matrix of a product on a new SO (not saved),
a js error was raised (wrong qweb template rendering).

This is due to a wrong check when loading the matrix data,
in the case of a new record, the data wasn't correctly updated
on all widgets, resulting in an opening of the matrix with the results
of the last matrix changes (since the information is transferred in the same field).

This commit:

* Ensures that the correct data is taken to open the matrix (solving the main
problem of matrix update on new records)
* Improves test coverage to cover untested buggy situation
* Fixes another error found while improving test coverage:
The edition of existing quantities was wrongly creating new lines, instead of updating
existing ones.  Simplify lines comparison to ensure the matrix won't generate two lines
for the same variant combination.

closes odoo/odoo#54917

Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
2020-07-29 13:46:46 +00:00
Julien Mougenot d3f0632f49 [FIX] web: datepicker get correct database format
Before this commit, the format used by both date and datetime picker
components depended on default props which are evaluated on module
loading. This was an issue because the "time" module did not have time
to load and fetch the correct database value, hence using the default
ones.

Now, the format is evaluated on component instantiation, giving enough
time to the "time" module to load.

Task 2307258

closes odoo/odoo#55113

X-original-commit: 792b565a65a8c9f65bf13e94f30b88913f2bfa7f
Signed-off-by: Paul Morelle <madprog@users.noreply.github.com>
Signed-off-by: Julien Mougenot (jum) <jum@odoo.com>
2020-07-29 11:20:16 +00:00
Robin Heinz dbbf6a8731 [IMP] point_of_sale: customer flow improvement.
Improve the flow of the customer list and edit to fit better with odoo.

closes odoo/odoo#54571

Task-id: 2294251
Related: odoo/enterprise#11891
Signed-off-by: pimodoo <pimodoo@users.noreply.github.com>
2020-07-29 08:39:40 +00:00
Thibault Francois fb396a954d [FIX] hr_timesheet: Timesheet in multi company
Allow user that have a employee in a company A
and that is allowed on company A and B to timesheet
on company B

Problem:
A user have access on company A and B but is link to
an employee that belong to company A. He want to timesheet on a
project from the company B. He gets an error
"Incompatible companies on records".

Since most users are linked to only one employee that belongs
to one company. It's impossible to have consistent companies.

Solution:

The employee shouldn't be checked on the timesheet

closes odoo/odoo#55074

X-original-commit: 7eada96b8fc1c370801ff42231167885cc8e46bc
Signed-off-by: Olivier Dony (odo) <odo@openerp.com>
2020-07-29 09:02:49 +00:00
Lucas Perais (lpe) 559a9cf018 [IMP] *: adapt some list views to the action button in controlPanel
task-2246383

closes odoo/odoo#54593

Related: odoo/enterprise#11992
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
2020-07-29 09:11:52 +00:00
Lucas Perais (lpe) 49d9771c56 [IMP] web, base: action buttons in list's controlPanel
This commit introduces a new semantics to define action and method buttons
in the list view.
The aim of this feature is to be able to do some actions on selected records, or on the entire
records' domain with the help of buttons located in the controlPanel, much like the form view header buttons.

To define such buttons, one must add a `header` node in the list view's xml definition
```
<tree>
  <header>
    <button type="action|object" name="actionId|methodName" string="button's text" context="{}"/>
  </header>
  <field name="fieldName" />
</tree>
```

task-2246383
2020-07-29 08:59:42 +00:00
Andrea Grazioso (agr-odoo) 97cdcc05f1 [FIX] stock,sale_mrp: Inventory adjustment not possible
1) Create a stockable product > Add some quantities on hand
2) Edit this product > set it as a consumable or service
3) Create an inventory adjustment on all products

Error will raise "Something went wrong! You can only adjust storable products.

This occur because when switching product type the available quantity
was not cleared, so it will get in the next inventory, but only storable
products can have inventory. So the product should to have no
quantity left before switching type

opw-2300478

closes odoo/odoo#55062

X-original-commit: be17e31307070498ba9ac7dc594443730caa7404
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
Signed-off-by: agr-odoo <agr-odoo@users.noreply.github.com>
2020-07-28 14:40:25 +00:00
Paul Morelle 544e22f4f2 [FIX] mass_mailing: respect mail_server_id for test emails
When sending a test email for a mass mailing, it was using the default
server, ignoring the one that could have been set on the mailing object.

This commit fixes this issue, so that the way the test emails are sent
is even closer to the real process.

closes odoo/odoo#55072

X-original-commit: 6af6e4714f2ccc703e9a3189b12a2317bd6af49c
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
Signed-off-by: Paul Morelle <madprog@users.noreply.github.com>
2020-07-28 15:43:36 +00:00
Nicolas Lempereur fff793f7d7 [FIX] web_editor: carriage return in source mode
Enter keypress browser event were removed in 3c372d1da8.

It was reintroduced in text fields with d2f024d254 and this PR do the
same and reintroduce it for source mode of FieldHtml (`html` widget).

opw-2302605
closes #55066

closes odoo/odoo#55081

X-original-commit: b10ca1f6094b7c8e6e222aa0ea3d1f891e79379a
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
2020-07-28 18:16:22 +00:00
Nasreddin (bon) d432b34728 [FIX] website_slides: Traceback when no link provided for video
Issue

	Traceback raised in case no link provided when content type
	is a video.

Solution

	Format url only if provided.

Note: also fix issue with scheme (embedCode src could start with //)

Related fix : https://github.com/odoo/odoo/pull/54536
opw-2294344

closes odoo/odoo#55079

X-original-commit: 49a18eec21bad3d193804a3aa630e453b85318e9
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
2020-07-28 17:45:09 +00:00
6aa6c321a6 [IMP] web: remove min date limitation of year 1900
Before this commit, user could not selecta a date before year 1900.
This was an historical limitation due to python < 3.2 that didn't
support dates before 1900.

After this commit, user can select any date, user can select any
date from 01/01/0001.

taskID: 2166761
Fixes #41788
Closes #43055

closes odoo/odoo#51406

Signed-off-by: Géry Debongnie (ged) <ged@openerp.com>
Co-authored-by: Mohammed Shekha <msh@odoo.com>
Co-authored-by: Aaron Bohy <aab@odoo.com>
2020-07-28 14:02:10 +00:00
Nicolas Martinelli 684b628c5a [FIX] purchase_mrp: receive kits with multiple UOM
- Create 3 products A, B & C
  A is in Units
  B is in kg
  C is in m
- Create a BOM kit for A using 1 kg of B and 1 m of C
- Create a PO for A, validate
- Receive the picking

An error is raised: "Conversion from Product UoM ... to Default UoM ...
is not possible as they both belong to different Category!."

It happens because `_compute_qty_received` incorrectly converts
quantities.

The computation of the quantity received for kits is done in 2 steps:
first we compute the quantity the same way we do it for a regular
product, then we overwrite the quantity with the value computed for
kits.

We can compute the quantity correctly at once by calling `super` only on
lines which are not kits.

opw-2302807

closes odoo/odoo#55047

X-original-commit: b82f71dac9452de9c1e16cde552fe260fec3c262
Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
2020-07-28 12:38:33 +00:00
Xavier Morel c8063af7a0 [IMP] core, account, lunch: make <menuitem> recursive
For clarity, some data files are formatted as pseudo-tree
structure. This is somewhat confusing and dangerous when the structure
has no meaning... so add meaning:

* allow nesting menuitems, nested items are set as children to the
  parent they're nested in
* update schema to allow an icon *or* a parent on regular menu items,
  and neither on nested (they have an implicit parent meaning can't
  have an icon)
* remove attributes which don't actually exist from the menuitem
  schema
* also type sequence as an integer while at it

Convert two large-ish menuitem data files to recursive form.

closes odoo/odoo#54564

Related: odoo/enterprise#11887
Signed-off-by: Xavier Morel (xmo) <xmo@odoo.com>
2020-07-28 13:03:13 +00:00
Xavier Morel 6835aeb0de [REM] core, *: deprecate <act_window> and <report>
Convert deprecated tags through the codebase.
2020-07-28 13:03:13 +00:00
Xavier Morel 96a3265118 [FIX] doc: remove <act_window> and <report>
* remove <report> and <act_window> form the backend tutorial
* remove documentation for <report> in the report doc

Also various fixes and improvements:

* add ACL to the wizard in the tutorial, as transients now require ACLs
* fix indentation & spacing in rST
* reword a few bits
* improve styling of footnote references (and recompile stylesheet
  with recent lessc which apparently changes its output formatting
  quite a bit)
2020-07-28 13:03:13 +00:00
Xavier Morel 48335c04bf [IMP] core: orm doc
* fix link from backend tutorial to log_access section
* flesh out log access documentation
* add documentation for log_access itself & improve doc for a few
  other model-level attributes
2020-07-28 13:03:12 +00:00
Nicolas (vin) c09c6a92e1 [IMP] account: Make analytic fields read-only
Analytics fields are currently updatable when the move has been posted,
even though editing them as no effect.

This change make them read-only when the move has been posted.

Task ID: #2299319

closes odoo/odoo#54521

Signed-off-by: Cedric Snauwaert (csn) <csn@openerp.com>
2020-07-27 05:04:39 +00:00
Benjamin Vray 501487c9d7 [FIX] website: fix header effects issues with hamburger menu
Do not update to main padding-top when opening an hamburger menu with
a fixed header. Close the menu hamburger if the page is scrolled.

Part of https://github.com/odoo/odoo/pull/51446
task-2229127

closes odoo/odoo#55045

X-original-commit: c06218408df4c8ec2fa3902e0cc03468c32dd36d
Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
2020-07-28 12:20:17 +00:00
Benjamin Vray 4848c3aed7 [FIX] web_editor: fix overlay when scrolling
Since the new effects on the header, the overlays do not overlap
correctly after the page has been scrolled. Now we hide the overlays
during the scrolling and show/recompute it after the scrolling.

Part of https://github.com/odoo/odoo/pull/51446
task-2229127

X-original-commit: 209a94d8c4fcdc2e74860c9392fc14a35aec52ed
2020-07-28 12:20:16 +00:00
Benjamin Vray 2ebbdef089 [FIX] website: fix standard effect with Logo on top/below
Fix the standard effect with template logo on top/below to avoid
an hopping when scrolling.

Part of https://github.com/odoo/odoo/pull/51446
task-2229127

X-original-commit: 444b8b8a8d2014d0465a6ff00ce23b2ca1fca66a
2020-07-28 12:20:15 +00:00
yhu-odoo 7b8035563f [IMP] (purchase_)stock: reserve and replenish automatically
1. When reservation can't be done for some products, we automatically
evaluate their reordering rules and create the corresponding
replenishment document.
2. When receiving products in stock, automatically check if some stock
moves are available and assign them.

Task 2244230
PR #52433

Signed-off-by: Simon Lejeune (sle) <sle@openerp.com>
2020-07-28 09:47:04 +00:00
jerome hanke (jhk) d6d540a8d5 [FIX] sale: portal generates pdf for the chatter in a separate request
Steps to reproduce:
- install studio, website and sales
- go to sales > open studio > go to 'reports' > Quotation/Order
- add a field anywhere on the report with the field expression set to
"doc.signature" > save
- go to sles > create a quotation > send by email > send > go to the customer portal
- sign and send the quotation > go back to the edit mode > open the pdf attached
to the latest message in the chatter

Previous behavior:
the custom field added was not rendered properly,
the attachment is not available during the request and the generated
pdf shows the placeholder image instead

Current behavior:
the message posted in the chatter is generated in another request,
this makes the attachment available

opw-2260989

closes odoo/odoo#54955

X-original-commit: a15cbb0a7be666d3ad438f6470d29cda75c24027
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
2020-07-27 09:39:25 +00:00
Siddarth Gajjar 7146ee0231 [IMP] *: clean leftovers 'col_group_by' and 'measures'
* hr_recruitment, point_of_sale

Context keys 'col_group_by' and 'measures' are ignored since v8 or
v9. They have been respectively replaced by 'pivot_column_groupby'
and 'pivot_measures'/'graph_measures'. This commit cleans the few
filters that were still using it.

Task 33834

closes odoo/odoo#23234

Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
2020-07-28 07:22:22 +00:00
Jason Van Malder 974bc0d2df [FIX] sale: fix safari excluded variant indistinguishable in select
Issue

	- Safari
	- Sales with product configurator
	- Have a product with color black & white
			      size M, XL
	- Exclude M size when color is white
	- Create a SO with that product
	- Select white color

	The size's M option is not grayed in the select

Cause

	We do not disable the option when it's not available.
	We are just adding a css class which grays the option.

	Safari ignores the style

Solution

	Since the flow can't be completed if you select a
	grayed item, disable the option

OPW-2289666

closes odoo/odoo#54993

X-original-commit: 6150311b72089e3fbae6bc27551bc7f4792e68dd
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
Signed-off-by: Jason Van Malder (jvm) <jvm@odoo.com>
2020-07-27 14:49:18 +00:00
Jeremy Kersten cc6000abfa [FIX] website_sale: align abandoned cart period
Using same domain
Using similar filter by week/month/year

closes odoo/odoo#55020

Signed-off-by: Jérémy Kersten (jke) <jke@openerp.com>
2020-07-27 15:23:08 +00:00
Swapnesh Shah b6bc6453e4 [FIX] website_sale: align abandoned orders count and records
The purpose of the button "Abandoned Carts" on the eCommerce dashboard is to
encourage user to send recovery emails.
Before this commit, the domain wasn't correct as we considered all the
abandoned cart, including the ones which an email was sent.

After this commit, the domain of the filter "Abandoned Carts" took into
consideration the abandoned cart and the carts for whom it is necessary
to send an email.

This commit closes #52799
2020-07-27 15:23:08 +00:00
Arnold Moyaux 4f7115dc47 [FIX] purchase_stock: PO lines not merged
Some PO lines could be ignore during _run_buy and _find_candidate.
It happens since the sorted only take a function and a string do
nothing.

Close #53247

closes odoo/odoo#55011

X-original-commit: 09d77ff467a3ce5cde78da7e153d33d881fb9b87
Signed-off-by: Arnold Moyaux <amoyaux@users.noreply.github.com>
2020-07-27 16:37:46 +00:00
Goffin Simon 805e4ab5a1 [FIX] sale_coupon: Promotion programms not company specific
Steps to reproduce the bug:

- Create a promotional program P with company A
- Change to company B and create a SO
- Click on Promotion

Bug:

The promotion created in company A was applied to SO created in company B

opw:2303169

closes odoo/odoo#55010

X-original-commit: 3e88c5157ca344208ad4853c529baab732c1c2dd
Signed-off-by: Simon Goffin (sig) <sig@openerp.com>
2020-07-27 16:36:31 +00:00
Nicolas Martinelli 5670a102ac [FIX] repair: sequence at creation
- Create a repair order
- Cancel the creation
- Create another repair order

There is a gap in the sequence number.

The gap is due to the fact that the sequence number is consumed by the
`default_get`.

Although this is a change of behavior, the actual one is not really
expected. Even if a gap is possible with the sequence, we don't want to
consume a number every time we get the default values.

opw-2301412

closes odoo/odoo#55005

X-original-commit: 9d7d618220e27024321a75be0058db2289115af2
Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
2020-07-27 16:00:07 +00:00
jvm-odoo 054894c35c [FIX] product: fix dynamic product variant archiving
Issue

	- Install Sales with Product Configurator
	- Create a product with 2 dynamic variants:
		- Color: blue, red
		- Size: S, M
	- Create a quotation with that product (any variant)
	- Sales > Products > Products Variants

	Your product variant is there

	- Modify your product template and add "green"
	  to colors
	- Sales > Products > Products Variants

	Your product variant is archived

Cause

	The logic which determines which variant
	should not be archived is only applied
	on products that don't have dynamic variants

	See https://github.com/odoo/odoo/blob/820fe9a025e34e81368a189ee295b4abcf9fcbda/addons/product/models/product_template.py#L576

Solution

	Do a separate logic for dynamic variants that doesn't compute
	all possible combinations.

	But being sure that it:
		- doesn't archive when adding/removing a value
		  to an existing attribute line
		- archive when adding/removing a new attribute line

OPW-2293346

closes odoo/odoo#55016

X-original-commit: 8517fdfa2605e8d15f5e38f2074ece7ba543d56b
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2020-07-27 17:27:14 +00:00
Victor Feyens 8d96f92bb1 [FIX] doc/views: header should be outside of sheet tag.
Forward-Port-Of: #54984

Original commit: d5e807e47edc641c8d9d97fe59d8d9eba40bd5af

closes odoo/odoo#55015

X-original-commit: e2c358adc7de11de28f18dbe36963ba71f95dd19
Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
2020-07-27 17:22:14 +00:00
Victor Feyens 6c53332358 [FIX] doc/views: templates attribute isn't supported in calendar views.
Since
https://github.com/odoo/odoo/commit/369c20a99bd25172f72f4efde870172a4729aadc:
event cards cannot be customized anymore, only the popover is adapted
depending on <field> attributes inside the calendar tag.

Forward-Port-Of: #54984

original commit: 920599a46e1221c03a20e005a7ad5c61fa9107a0

X-original-commit: ef18d482a58bbff24ce1217619df603ec4670002
2020-07-27 17:22:13 +00:00
Arnold Moyaux 04ff5d0292 [FIX] mrp: Usability bom_id on operation
closes odoo/odoo#54692

Related: odoo/enterprise#11949
Signed-off-by: Arnold Moyaux <amoyaux@users.noreply.github.com>
2020-07-27 15:03:05 +00:00
Arnold Moyaux 3355371f34 [IMP] mrp: editable timer 2020-07-27 15:03:05 +00:00
Arnold Moyaux 27d6f88ab2 [FIX] stock: no label on optional
We wanted the JSON popover to have no label on the tree view but
it's problematic with the optional feature that display also no
label on the optional dropdown. It's possible to combine both
by using nolabel="1" instead of an empty string as name.
2020-07-27 14:42:48 +00:00
Nicolas Lempereur 922c7c722d [FIX] web: show digital signature in PDF
Show digital signatures items in PDF.JS preview even if the signature
verification is not implemented.

From discussion in mozilla/pdf.js this is like this because they don't
want to give the user a false sense of "the digital signature has been
verified" when it has not, but for a preview of the PDF this seems
misleading, in any case the user can have a full fledged PDF reader and
know if the document is well signed then.

https://github.com/mozilla/pdf.js/ issues/4743

opw-2287840
closes #54922

closes odoo/odoo#54988

X-original-commit: 820128385c523f562b9ee82698c81daa63149bb7
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
2020-07-27 13:58:00 +00:00
Hardik Prajapati 7aafa20509 [FIX] web: list: hide export button when list empty
Before this commit, at first rendering, the export button was
displayed in the list view even if the list was empty.

The issue occurred because at first rendering, the buttons aren't
moved inside the control panel yet (this is done in the 'mounted'
hook of the control panel). As we render in a fragment, the hook
is called later on, when everything is ready and inserted into the
DOM.

We'll get rid of these painful manipulations as soon as everything
will be converted to OWL.

Task 2294306

closes odoo/odoo#54307

Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
2020-07-27 12:54:57 +00:00
Jorge Pinna Puissant 97425653af [FIX] hr_timesheet: timesheet button in employees view
Fine tuning of c839ecda6c696ac54ceaf24b2ee1816cb358052a

opw-2285695

closes odoo/odoo#54973

X-original-commit: 15ce41cd1ec8a9e80ec59fa4a0d26329fc1225f9
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
Signed-off-by: Jorge Pinna Puissant (jpp) <jpp@odoo.com>
2020-07-27 11:09:12 +00:00
Pierre Masereel 056246665f [IMP] pos_sale: speciify table for qty field in request
In the sale_report sql request for pos orders, the field qty of order
lines is used without specifying the table it comes from.

To avoid ambiguity if a field with same name is declared in another
table of the join, we prefix it by its table.

ISSUE-54933

closes odoo/odoo#54960

Signed-off-by: pimodoo <pimodoo@users.noreply.github.com>
2020-07-27 09:48:33 +00:00
Antoine Prieels a4d6b0d286 [FIX] point_of_sale: Open Cashdrawer when no printer is selected
- In the POS config, check "Receipt Printer"
- The "Cashdrawer" checkbox will show, check it
- Uncheck "Receipt Printer"
--> Cashdrawer is still checked, so if you open the POS and validate
an order paid in cash, it will try to open the cashdrawer, but there's
no receipt printer so the command fails with a traceback.

opw-2303986

closes odoo/odoo#54963

X-original-commit: 9bd5d6d5b19c7bf44c5ba9ee544812bdfa558217
Signed-off-by: pimodoo <pimodoo@users.noreply.github.com>
Signed-off-by: Antoine Prieëls <aprieels@users.noreply.github.com>
2020-07-27 10:15:09 +00:00
Xavier Morel 92903e22f8 [IMP] core: reporting after tests
Currently there are a few issues with testing reporting (at the
command-line):

1. there is a global report after at_install tests, but it gets
   "scrolled off" by long post_install tests, and is thus easy to
   miss
2. with test tags, it's easy to fat finger a typo and run 0 tests,
   which look like everything's running fine (no failure)

To improve this, print a global report at shutdown (in
`--stop-after-init` mode if tests are enabled) which recapitulates the
test results *and prints a warning if no tests were run at all*.

Also update the reporting collection to make this more reliable:

* have `run_unit_tests` return `None` if it has run no tests, the
  assertion reporting machinery counts this as neither success nor
  failure which is exactly what we want
* have load_test only report a success *if files were actually
  loaded* (by having `load_data` return that information)

Task 2301268

closes odoo/odoo#54812

Signed-off-by: Xavier Morel (xmo) <xmo@odoo.com>
2020-07-27 09:30:51 +00:00
Dharmraj Jhala 297c3d8378 [IMP] mass_mailing_sms: improve shortened URL detection in tests
Before this commit, in gateway tools, we used to consider URL as a
shortened which was having `/r` in it. However this is not true in
all cases. Any random URL can have `/r` in it but it might not be
a shortened one. It caused random failures on runbot time to time.

This commit makes a bit precise search (`/r/`) to consider URL as
a shortened one and thus avoiding those random test failures on the
runbot.

TaskID - 2276386

closes odoo/odoo#54944

X-original-commit: b8045b49d0693292e6240dfb3acd7c9a6450ad77
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2020-07-27 08:04:10 +00:00
Lavish Chhatwani c5d98aeccb [FIX] crm: set 'info' alias to default data salesteam
This commit sets 'info' alias on the default sales team and sets 'admin' as a
default user for the same. After a long debate on default alias configuration
"it will work on SaaS and other people will be careful when deploying" won.

Task ID-2284840

closes odoo/odoo#54943

X-original-commit: 46d616643ba684596b709cd7e65536781dfa5d51
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2020-07-27 08:03:42 +00:00
Lavish Chhatwani 29c39dab3b [FIX] crm : prevent a false positive warning ribbon for phone on lead
In the lead, we compute the phone number to make it formatted to match
with the international phone number format.

Before this commit, this formatted number was used for comparison with
partner's phone (which is not formatted), and so, even if both the
numbers are same, the warning ribbon appears due to different formats
which is not correct behavior.

This commit fixes the issue by comparing both the formatted number to
remove the false positive warning ribbon and thus making sure that it
appears only when there actually is a difference between lead's phone
and the phone number set on partner.

Task Id-2274752

closes odoo/odoo#54942

X-original-commit: d29862c1de6208f7fdb7c8104afe0d35241d130b
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2020-07-27 08:03:19 +00:00
vha-odoo 89d5628c9d [FIX] mail: remove unnecessary gap between fields
prior to this commit :
there was a big gap between subject and recipients in mass mailing

with this commit:
the gap has been removed by improving css related to  mail emoji
drop-down (resopnsible for this gap).

task - 2291575

closes odoo/odoo#54940

X-original-commit: ae4c9be4419604affd980ae80b48f738a70b0b2c
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2020-07-27 07:47:12 +00:00
Dharmraj Jhala 0e57bfd453 [FIX] sms, test_mail_full: make contextual action work for sms templates
While creating contextual action for an sms template, the composition mode
may be decided on the fly, based on number of records and on context the key
`default_composition_mode`, which is set to 'guess'.

It used to work before a recent refactoring[1], because the composition
mode was changed in the default_get, and was being set to appropriate
value instead of 'guess'.

After this refactoring, the composition mode is not being set in the
default_get but is being computed, so the key `default_composition_mode`
tries to set the composition_mode selection field to 'guess', which is not
available in the selection values, resulting into traceback.

This commit fixes the issue by renaming the context key(removing 'default'
prefix) to avoid setting the mode directly and instead let the compute method
decide the composition mode based on context key and number of records.

[1] - https://github.com/odoo/odoo/commit/e02137c48562d824e3e01054e31dae383e5843e2

TaskID - 2286959

closes odoo/odoo#54938

X-original-commit: 2b9ea3d93445e05cb0440aab33f2bf9e066b0fa5
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2020-07-27 07:27:18 +00:00
Nicolas Martinelli dafe96b3da [FIX] website_links: prevent display of huge list
- Create 80k UTM sources
- Go to the Website
- Promote a page (e.g. an event)
- Select a source

The web browser freezes.

It happens because Select2 tries to display all sources at once.

To prevent this, we force at least 3 characters before searching and
hence displaying the results. Note that a such high number of UTM
sources is reached because of automatic generation of random values in
mass mailing. Therefore, the combination of 3 characters narrows down
the search result drastically.

opw-2289249

closes odoo/odoo#54947

X-original-commit: 7c7986361704d7b82b115499e64c47eb74ab655f
Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
2020-07-27 08:24:30 +00:00