Commit Graph
126133 Commits
Author SHA1 Message Date
Christophe Simonis 617652bbfe [MERGE] forward port branch saas-15 up to 9878db14f5 2019-01-10 17:00:16 +01:00
Christophe Simonis 9878db14f5 [MERGE] forward port branch saas-14 up to a449b063b0 2019-01-10 16:59:00 +01:00
Christophe Simonis a449b063b0 [MERGE] forward port branch 10.0 up to 5f12e244f6 2019-01-10 16:58:38 +01:00
Laurent Smet ec25b9d01b [FIX] account: Prevent crash when having custom coa
- Create manually an account.payment after having created manually some journals
(without installing a coa).
- Install a module containing a coa and calling try_loading_for_current_company or depending
of other module doing such things.

=> Crash because company.chart_template_id is not set.

-opw: 1921711

closes odoo/odoo#30117
2019-01-10 13:53:14 +00:00
Nans Lefebvre a7cbac305e [FIX] web: reset offset in the search more view dialog
Start on the modal obtained by a "search more". The offset is never reset.
So suppose you are on page 2, looking at record 81-160.
Do a research that gives less than 80 records.
The result of the search is nothing, since is has been done with a 80 offset.
It should be reset to 0 when we do a new search.

opw 1920826

closes odoo/odoo#30109
2019-01-11 15:07:40 +00:00
Nans Lefebvre f8e953fdd6 [FIX] base: set related crud_model_name on the correct field
Create an automated action that creates a new record (of target crud_model_id).
Try using a link_field_id: nothing appears to be selectable, even if some fields
satisfy the intended conditions.
The issue is that the crud_model_name field was related to crud_model_id.name,
instead of the correct crud_model_id.model (note the apt naming).
Note that in the onchange the value of crud_model_name was correctly set to
crud_model_id.model, adding to the confusion.

opw 1910671

closes odoo/odoo#30145
2019-01-11 08:56:02 +00:00
Christophe Simonis 5f12e244f6 [IMP] base: compute implied groups in SQL
SQL improve the speed of the implied group
VS the orm version.

closes odoo/odoo#30108
2019-01-10 13:48:40 +00:00
Christophe Simonis 96e800703b [MERGE] forward port branch saas-14 up to 390d8594b0 2019-01-10 13:22:07 +01:00
Christophe Simonis 390d8594b0 [MERGE] forward port branch 10.0 up to b131658966 2019-01-10 11:33:40 +01:00
Christophe Simonis 3390fec761 [MERGE] forward port branch 12.0 up to 744c073abb7
closes odoo/enterprise#3394
2019-01-09 15:35:00 +00:00
Lucas Perais (lpe) b87879c1f6 [FIX] web_editor: icon widget complies to api
the search method should return a Deferred as explicit in MediaDialog

OPW 1919549

closes odoo/odoo#30077
2019-01-09 14:32:04 +00:00
Romain Derie 20e9d77be8 [FIX] website: correct order when copying view children on COW
Before this commit, a generic view tree could be valid but impossible to copy
on a COW specific tree.

This was because when looping through inherit_children_ids to copy them, they
would be sorted by the ir.ui.view sort order (name, priority, id).
Indeed, when applying view inheritance and reading a view arch, children are
sorted by (priority, id).

Thus, if sorting the children by (name, priority, id) was different than
sorting by (priority, id) and the children view would conflict in that new
order, the COW would raise an error "can't find DOM element"

Step to reproduce:
  - Create a parent view with just a DIV in arch
  - Add a child view that add something inside that DIV
  - Add another child view with a name alphabetically lower than the other
    child and that replace the DIV by something else, like a SECTION
  - Everything works as expected, when reading the parent view arch, the first
    child is inserting something into the DIV and then the second is replacing
    the DIV
  - Now try to trigger the COW on the parent view by writing something on it in
    a website context
  - It will crash as the child views will be copied in another order, sorted
    firstly by name.
  - Indeed, when reading parent view, the second child will be copied first as
    it's name is lower than the first, it will then replace the DIV by a SPAN.
    When trying to copy the other child view that is supposed to insert
    something into the DIV, the DIV will not be found and it will crash.
2019-01-09 13:09:26 +00:00
Nicolas Martinelli 3ad5748cef [FIX] purchase: auto-complete order
When using the 'Auto-Complete' feature of a vendor bill, oldest vendor
bills are suggested first.

This is because the `_order` uses the `vendor_bill_id` and the
`purchase_order_id`. In the view, we have a mix of positive, negative
and null ids, therefore this can't work.

We sort on the date and the name instead, which gives a more reliable
result.

opw-1925910

closes odoo/odoo#30299
2019-01-17 09:41:41 +00:00
Martin Trigaux 766da2017c [I18N] l10n_be: update chart of account translations
To reflect the latest accounts and taxes
Update nl.po files to help translators
A future commit will translate the missing entries

closes odoo/odoo#30297
2019-01-17 09:17:07 +00:00
Pierre Masereel 27cc1fb3af [FIX] snailmail: background layout footer
In the background layout footer, it happens that the content is over a
zone that must stay blank. That's why w've added a left-padding to the
footer.

OPW-1928366

closes odoo/odoo#30296
2019-01-16 15:17:14 +00:00
Sébastien Theys 13b104bf9e [FIX] sale,sale_management: prevent traceback on get_access_action
The field `sale_order_template_id` is only defined on `sale_management`, so
calling that method without `sale_management` would crash (traceback).

The method was in `sale_management` in the first place but commit
34c47eecd3 happened and some mistakes were made
that day.

PR: #30000

closes odoo/odoo#30294
2019-01-17 08:16:11 +00:00
Sébastien Theys 9df7d244a0 [FIX] tests: fix chrome headless to work with any local HOST
Before this commit, changing the value of the HOST variable didn't work because
it wasn't correctly used everywhere.

Moreover, the `web.base.url` was not correctly set: it is set during
authenticate, but when calling it from the console instead of from a request,
which is the case for tests, it is not able to grab and set the URL as needed.

PR: #30000
2019-01-17 08:16:11 +00:00
Christophe Simonis 2d824a5b7a [FIX] test_mail: bump expected query count
The prefetch hell patch [1] generate one more query.

[1] a07a076c45
2019-01-08 15:35:34 +01:00
Gert Pellin 9246375b25 [fix] point_of_sale: payment screen backspace
before the fix if hitting the backspace in point of paiment screen would
triger the keypress event twice.

removed the double eventhandler

resolves https://github.com/odoo/odoo/issues/29911

closes odoo/odoo#30031
2019-01-08 13:17:16 +00:00
Jorge Pinna Puissant 13e47f508f [FIX] payment_authorize: customer profile without email
opw-1920083

Before this commit, an error arrived when creating a customer profile
without email.
Now, if the email don't exists we send an empty string to Authorize.

closes odoo/odoo#30075
2019-01-09 13:44:06 +00:00
Gert Pellin 313b133878 [FIX] point_of_sale: Correct move amount lot
Before this fix, if 2 or more sale lines have the same product with different
lot-numbers the amount for each move will be set to the total amount of the
product.

This fix resolves this problem and will only count the amount sold of
each lot.

Resolves https://github.com/odoo/odoo/issues/30006

closes odoo/odoo#30019
2019-01-09 11:31:42 +00:00
Romain Estievenart 5efec7ccdd [FIX] sale_timesheet: responsive table
On small screens, when we click on the overview of a task
inside the "project" app, the displayed table doesn't fit the screen.

This commit only add missing parent "div.table-responsive" to add
responsive support.

A better fix has been merged in master, see:
https://github.com/odoo/odoo/commit/dc017d17e9170d3fc0a5104ab9dc84f748bc097a

opw-1907877

closes odoo/odoo#29971
2019-01-08 14:25:37 +00:00
Nicolas Martinelli 3929e419ff [FIX] stock: assign partner
- Create a SO with a stockable product, validate
- On the corresponding picking, change the partner
- Print the 'Picking Operations' or 'Delivery Slip'

The partner printed is the partner of the SO, not of the picking.

This was reported many times in the past, and is quite confusing. It
happens because the partner on the `stock.move` remains the partner set
on the SO.

We shouldn't change the reports, nor automatically propagate the change
since it might cause issues, e.g. in case on dropshipping or manual
creation of the picking.

Therefore, we add an action which allows to set the partner on the stock
move manually.

opw-1917851

closes odoo/odoo#29939
2019-01-08 13:41:07 +00:00
Jorge Pinna Puissant b131658966 [FIX] account: error in Base amount tax
opw-1917605

Before this commit, when accounting is set to global rounding, the base
amount per tax is not correctly calculated.

Now, the Base amount per tax is calculated adding the rounded lines.

To test this issue, you need to set to global rounding and create a
customer invoice with the following lines :
line 1 = Qty:40; unit price:2.27; tax:15%; discount: 10%
line 2 = Qty:21; unit price:2.77; tax:15%; discount: 10%
line 3 = Qty:21; unit price:2.77; tax:15%; discount: 10%

When the invoce is printed, you would notice that the amount is 186.43
and it should be 186.42.

closes odoo/odoo#30021
2019-01-08 13:13:36 +00:00
qsm-odoo 42230ed22e [FIX] website_sale: make eCommerce animations work in all browsers
The eCommerce sometimes animates product images when they are put in
the cart / wishlist / comparison panel. Those animations did not work
on Firefox and IE and made strange scrollbars appear instead.
2019-01-08 14:02:01 +01:00
Christophe Simonis b50883d17b [MERGE] forward port branch 11.0 up to c07b7200b2 2019-01-08 11:52:15 +01:00
Christophe Simonis c07b7200b2 [MERGE] forward port branch saas-15 up to e1c7fefe89 2019-01-07 18:19:25 +01:00
Christophe Simonis e1c7fefe89 [MERGE] forward port branch saas-14 up to cdb0c08cb9 2019-01-07 17:30:57 +01:00
Christophe Simonis cdb0c08cb9 [MERGE] forward port branch 10.0 up to d4024a713c 2019-01-07 17:30:11 +01:00
Francisco Fernández d4024a713c [CLA] PlanetaTIC signs Odoo CCLA 2019-01-07 15:34:10 +01:00
Julien (juc) Castiaux fce729e65a [FIX] web_editor: banner not horizontaly centered
When creating a banner using the web editor, the targeted image
appears centered in the editor but is aligned on the left in the
email.

The issue also happened with other alignment (left in a centered
widget, right, ...) for example on outlook 2007 and should be solved
with this changeset.

opw-1904827
Co-authored-by: Nicolas Lempereur <nle@odoo.com>
closes #29985

closes odoo/odoo#29214
2019-01-07 13:49:33 +00:00
Humberto Arocha fe8e462822 [FIX] account: Wrong amount_currency on reconciling several lines
closes odoo/odoo#29966
2019-01-05 21:49:04 +00:00
Romain Derie 56243f4670 [FIX] website_gengo: override of static template was not working
The template `website_gengo.web_editor.TranslatorInfoDialog` was not used
anymore.
It is supposed to replace the one in `web_editor` module.

Among other things, 2972976 refactored the `web_editor` template to
contain only the modal body content. The bug might be coming from it.

closes odoo/odoo#29955
2019-01-04 16:43:19 +00:00
Arnold Moyaux 8c8b32e5e4 [FIX] mrp: manufacture user can not record production
Usecase to reproduce:
- Connect with demo user
- Create a MO w/h routing
- Confirm and produce it
- Record the production wizard

Access right error on product.product for field tracking

It happens because the wizard use a related to product.tracking howerver
it is not set as readonly on the view and send to the server as a value
on save. Since it write on a related field it will try to write on the
linked model(product.product).

This commit set the field as readonly so it is not set to the server.
The field is just used inside domain and it is invisible to the user
so it do not modify any behavior.

opw-1918684

closes odoo/odoo#29942
2019-01-04 14:15:35 +00:00
Juan José Scarafía 0babee58b7 [FIX] base: correct typo in state name
Argentina state is Entre Ríos

closes odoo/odoo#29959
2019-01-07 08:58:54 +00:00
Lucas Perais (lpe) 0e0c726805 [FIX] purchase: don't change status when writing a note through the composer
Have a RFQ in draft. Log a note or send a new message, but use the full composer to do it.

Before this commit, the RFQ was set to sent

After this commit, it stays rightfully in draft
It is mark as sent, only if the button SEND RFQ is used

OPW 1908094

closes odoo/odoo#29902
2019-01-04 13:18:14 +00:00
Jorge Pinna Puissant 9cf6662880 [FIX] account: compute_fiscalyear_dates non leap years
Before this commit, when the fiscal year was setting to 29/02.
The function that compute the fiscal year dates gives an error.
This occurs when the date passed as parameter wasn't a leap year.

Now, for the non leap years we use the 28/02.

opw-1917035

closes odoo/odoo#29932
2019-01-04 10:23:44 +00:00
Alexey Pelykh 1ffc485689 [FIX] hr_holidays: extra space in state check
The condition was never validated

closes odoo/odoo#29898
2019-01-04 10:18:30 +00:00
Alexey Pelykh 11e5688d0f [CLA] Brainbean Apps OU signs Odoo CCLA 2019-01-04 10:18:24 +00:00
Nicolas Lempereur 27a084eb81 [FIX] web: attach document fix click on firefox
As of saas-11.3 there is a "Attach document" widget that is meant to
more easily add attachment.

But on firefox the click event is coming from the button, where on other
browsers it was possibly from a child element.

So the code expecting the child element did not work on firefox.

opw-1920842
closes #29903
2019-01-03 17:00:18 +00:00
Christophe Simonis 047bbc9c94 [MERGE] forward port branch saas-11.3 up to c41dcd4aa6c 2019-01-03 15:39:10 +01:00
Christophe Simonis d96c42ea88 [MERGE] forward port branch 11.0 up to 22637aadec 2019-01-03 15:31:05 +01:00
Raphael Collet a07a076c45 [FIX] models: avoid prefetch hell when reading fields
The method `read()` may be very slow when reading relational fields and
computed fields, because the computed fields can be computed on a recordset
that is larger than expected.

The issue occurs on model 'res.partner' when reading fields 'child_ids' and
'purchase_order_count', for instance.  Suppose we read those two fields on a
partner with 1000 contacts.  First, the one2many field is read from the
database and stored to the cache; the latter adds the value ids to the
prefetching of 'res.partner'.  Then, the fields are fetched from the cache.
When 'purchase_order_count' is accessed on the partner, the field is computed
on all its children as well...

closes odoo/odoo#29867
2019-01-03 12:45:48 +00:00
Jorge Pinna Puissant 8ac1cdde2e [FIX] web_planner: prepare_backend_url give a bad URL
opw-1920590

Before this commit, the function prepare_backend_url forced in the url
the view_type 'form'. This occurs because a misunderstand between the
fields ir.actions.act_window.view_type (That indicate if an hierarchy
in the view list exists, with as possible values : form and tree, which
can be mistaken as views types) and ir.actions.act_window.view_mode
(which is a list of allowed views).

Now, if not ask otherwise, the function give the url of the first
(the default) allowed view; or one of the allowed view if asked for it.

closes odoo/odoo#29882
2019-01-03 11:16:30 +00:00
Odoo Translation Bot d331d28fdf [I18N] Update translation terms from Transifex 2019-01-06 03:24:31 +01:00
Robot Odoo 5aa16e4507 [IMP] l10n_be_hr_payroll: Update salary rules up to 2019
Update withholding taxes and child allowances for the new fiscal year.

Documentation: https://finances.belgium.be/fr/entreprises/personnel_et_remuneration/precompte_professionnel/calcul

closes odoo/odoo#29931
2019-01-04 15:05:11 +01:00
Yannick Tivisse 3569d053d3 [IMP] l10n_be_hr_payroll: Update witholding taxes reductions up to 2019 2019-01-04 12:37:01 +01:00
Yannick Tivisse 551bffd3a1 [IMP] l10n_be_hr_payroll: Update 'bonus à l'emploi' up to 2019
Documentation: https://www.socialsecurity.be/employer/instructions/dmfa/fr/latest/instructions/deductions/workers_reductions/workbonus.html
2019-01-04 12:37:01 +01:00
Yannick Tivisse a6ba0b6678 [FIX] l10n_be_hr_payroll: Remove wrong rule
This rule is not correct, and shouldn't be applied here.
2019-01-04 12:37:01 +01:00
Yannick Tivisse f543cb2b18 [IMP] l10n_be_hr_payroll: Update salary rules up to 2019
Update withholding taxes and child allowances for the new fiscal year.

Documentation: https://finances.belgium.be/fr/entreprises/personnel_et_remuneration/precompte_professionnel/calcul
2019-01-04 12:37:01 +01:00