Commit Graph
117358 Commits
Author SHA1 Message Date
Katherine Zaoral edfcee0190 [FIX] base: fix name for country state of Buenos Aires
Change "Buenos Aires City" to "Ciudad Autónoma de Buenos Aires" accordingly to
http://www.afip.gob.ar/fe/documentos/TABLA%20PROVINCIAS%20V.0%20%2025082010.xls

closes odoo/odoo#28584
2018-11-20 18:11:20 +00:00
Julien (juc) Castiaux 124b5b8fee [FIX] product: disable "create & edit" shotcut for product variants
With the purchase module, when you create a new vendor, you can
select what variant of the product the vendor sells. The droplist
has the "Create & Edit" button to quickly create/edit variants.
This is not the wanted behavior. This PR removes the "Create & Edit"
suggestion.

opw-1909009

closes odoo/odoo#28845
2018-11-20 14:05:52 +00:00
Lucas Perais (lpe) e713ed2a69 [FIX] web: implement filter orderedBy
related to: #28446

On a pure list view, click on a column to sort the records by that field.

Save the filter as favorite

Reload, now apply the filter

Before this commit, there were two issues:
1. The order of the list was never propagated to search view, which couldn't save
the filter with its attribute "sort"

2. There was no mechanism to load the attribute sort from a loading Filter

After this commit, those two issues are corrected
Unfortunately, complex search view flows are not testable in v11.0

OPW 1906968

closes odoo/odoo#28766
2018-11-20 13:53:52 +00:00
Denis Ledoux 48dafd5b20 [FIX] point_of_sale: default pricelist test
The POS js tests expect the "Public Pricelist" when
selecting a lambda customer in the pos interface.

Nevertheless, when installing a localization
with a specific currency,
other than the currency of the public pricelist,
it creates a new pricelist called
"Default %(currency)s pricelist for %(company)s"
and sets it by default for the customers sale pricelist.
See
https://github.com/odoo/odoo/commit/787e1037cdca48fe361ae65d790056a3d57e6b67#diff-840bfc6fc7a986fbf0e248c83d2ac1d5R57

Therefore, in the POS js tests, the pricelist selected
when selecting a lambda user was no longer
'public pricelist' but the one mentioned above,
and the tests therefore failed.

The issue is solved by creating a dedicated "Public Pricelist"
for the purpose of these tests, and sets it by default
for the customer sale pricelist,
as well as for the pos config default pricelist.

The test case was to install `l10n_pe` with `point_of_sale`
while activating the test.
e.g. `-i l10n_pe,point_of_sale --test-enable`

opw-1890928
opw-1910249

closes odoo/odoo#28839
2018-11-20 11:59:45 +00:00
Nicolas Martinelli 8bff607f07 [FIX] point_of_sale: order currency
- Configure the company in USD
- Set-up the POS in EUR:
  Pricelist in EUR
  Payment journal in EUR
  Sales journal in EUR
- In the POS, sell a product (in EUR)
- Validate the session and post entries

The entry amounts are the EUR amounts, but they are posted in USD.

Long story short: nothing was foreseen to convert the amounts in the
appropriate currency.

Fixes #27175

opw-1904146
opw-1910248

closes odoo/odoo#28785
2018-11-20 09:44:37 +00:00
Raphael Collet b6d32de31e [FIX] base: optimize property fields
Implement the getter method in plain SQL.  This makes reading company-dependent
fields 33% faster (on 20000 partners, reading 'property_product_pricelist'
takes 3700ms instead of 5500ms.)

closes odoo/odoo#28769
2018-11-19 15:38:17 +00:00
Nicolas Martinelli 7e840a39a6 [FIX] web: External Link
In the case of a One2many list view in a `<group>` tag, the 'External
Link' button of a Many2one field (which allows opening the form view) is
not visible.

The `flex: 1 0 auto;` should not be applied in the list view.

Corresponding PR in v12: #28741
opw-1903158

closes odoo/odoo#28812
2018-11-19 19:21:38 +00:00
Nicolas Lempereur cac9173122 [FIX] web: m2o+o2m in o2m onchange no lose data
Steps:

- open a modal form view from tree view first line and make a change
- open a modal from the second line and make a change
- open the second line back: the change were lost

In a given number of conditions (a many2one inside the form view, there
is a one2many in the form view not inside the tree view, ....) this
happened because:

- when we save the first line, we get onchange data for the second one
- this onchange data can't be applied before second line is loaded, but
  it is saved so it can be applied if second line is ever opened
- when the second line is opened the saved change is applied => OK
- when the second line is opened a second time the saved change is
  applied again, possibly overwriting posterious change => BAD

With this changeset, when the record with unapplied onchange is loaded
for the first time, the unapplied onchange is applied only once.

Added test without the change failed with:

- only 1 turtle for second partner (result: 0 not 1)
- second partner turtle is Michelangelo (result: "" not "Michelangelo")

opw-1846820
closes #28644
2018-11-19 12:57:52 +00:00
Joseph Caburnay 108b43c60a [FIX] stock_account: corrected_value not considered as zero
The value of corrected_value can be very small, e.g. 1e-16, thus,
proper is_zero check should be used.

OPW: 1906519

closes odoo/odoo#28751
2018-11-16 10:28:58 +00:00
Odoo Translation Bot 1da3ff5a0a [I18N] Update translation terms from Transifex 2018-11-18 03:15:42 +01:00
Christophe Simonis 45d33f5357 [FIX] mail: correctly handle unset mimetype on safari
See 5e3b471f4a for more info
2018-11-16 17:25:55 +01:00
Raphael Collet f29df0f7a8 [FIX] stock: add index on stock.move.line.move_id
This field is a dependency of some computed fields, and has to be searched on
for triggering recomputations.  Without the index, the creation of stock moves
becomes slower as the table grows.

closes odoo/odoo#28757
2018-11-16 12:44:04 +00:00
Lucas Perais (lpe) 551be27593 [FIX] account: aged report: payment for future
Create an invoice for a day, and register a payment right away
BUT choose a date in the future for that payment

Imagine a French Check. You write it, and tell your partner to cash it in
10 days later

You would enter that transaction as a temporary payment
in your own books

OPW 1893646

Before this commit, the line of the partner did not appear in the aged
report after if the report was for the date just after the invoice date

After this commit, it does

closes odoo/odoo#28728
2018-11-15 13:33:00 +00:00
Christophe Simonis 468dab6748 [MERGE] forward port branch saas-15 up to 3c78026dc0 2018-11-15 18:57:09 +01:00
Christophe Simonis 3c78026dc0 [MERGE] forward port branch saas-14 up to 55104b915e 2018-11-15 18:15:47 +01:00
qsm-odoo 55104b915e [FIX] website_event: restore event list layout
Commit https://github.com/odoo/odoo/commit/b43364af7258e45ad846fbbf1f375ad26e58eb0d
introduced a row in a row. On a standard database, the bug is invisible.
When the user wants to edit that event list page, the right column... is
not on the right anymore.

Note: in 12.0, thanks to BS4, the bug was revealed even more as even on
a standard non-edited database, the bug is visible.

Closes https://github.com/odoo/odoo/pull/28693
2018-11-15 17:15:54 +01:00
Christophe Simonis 5523e6b1c9 [MERGE] forward port branch 10.0 up to 8a9569b31e 2018-11-15 17:00:52 +01:00
mao-odoo 8a9569b31e [FIX] auth_signup: Error when sending quotation
Fine tuning of this commit:https://github.com/odoo/odoo/commit/7501691da9a9dae832b7d6e78c6a5f57fc983b5c
Fields signup_token, signup_type, signup_expiration are protected
When sending a quotation (mail template 'Sales Order - Send by Email'):
the token needs to be read (and sometimes written)

opw:1907157
2018-11-15 15:28:48 +01:00
Goffin Simon 9148d86f35 [FIX] sale_stock: Decreasing ordered quantity on a SO
Steps to reproduce the bug:

- Set decimal precision to 7 for products.

- Order 2.000000 of a product.

- Deliver 2.6791200 of the product.

- Go back to the Sales order and change the ordered quantity to 2.6791200.

Bug:

A UserError was raised: "You cannot decrease the ordered quantity below the delivered quantity."

opw:1904580

closes odoo/odoo#28674
2018-11-14 12:42:56 +00:00
Robot Odoo d1509b2201 [FIX] stock: readonly on show details operations
commit c6b0d36622 introduced a wrong
domain. The readonly should be added if the show_operations is false
OR state is done AND is_locked is true.

close #28595

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#28603
2018-11-15 09:47:22 +01:00
Sebastien LANGE d5a540f3ba [CLA] Subteno IT 2018-11-14 16:37:23 +00:00
RomainLibert 8cdfe1d8fe [FIX] product: use product.pricelist in report product_pricelist
We were using hr.contribution.register as a doc_model on the
product.pricelist report which makes no sense since it should show
pricelist informations
2018-11-14 13:06:58 +01:00
Gert Pellin 0db2d4b307 [FIX] point_of_sale: order selector buttons
On to many open orders the + and - buttons will be pushed out of view.
This makes it impossible to close orders without checking out.
2018-11-14 09:31:42 +01:00
qdp-odoo 069c2f2304 [FIX] account: fix invoice access rights
removed the access right that was granting the read access on invoices to any internal user, because there's no reason to do so.

Fixes #28486
2018-11-13 17:18:43 +01:00
Lucas Perais (lpe) c70bdd0e4e [FIX] account: do not check for company logo when printing reports
Have a company that do not have a logo.

Try to print a "PDF report" from the accounting module

Before this commit, the simple company form popped up
with the purpose of force setting a company logo

After this commit, we assume it is not necessary to have a company logo on the reports

Note, because of 733ce266ef, we cannot do a save and print

OPW 1904764

closes odoo/odoo#28617
2018-11-13 11:15:24 +00:00
Sanjay Jamod 8f99013d01 [FIX] website: method should be called with action not with self
to avoid 'Expected singleton error'

OPW: 1909205

closes odoo/odoo#28648
2018-11-14 06:32:40 +00:00
lul-odoo 21976ca838 [FIX] base: Fix rng for 'templates' tag in calendar view
The following commit https://github.com/odoo/odoo/commit/76e6a0e3560db8257ab0d183463a894ace1e3a7e
renamed in the js calendar view file the template tag from 'template' to 'templates' but forgot
to rename it in the rng file. Since that commit templates in calendar views are not working.
This commit fixes this issue.

closes odoo/odoo#28601
2018-11-13 14:10:36 +00:00
Lucas Perais (lpe) 526bfca3af [FIX] base_address_city: correct view_get with address fields
Have a partner with children exceeding the limit of the kanban.
Edit,
Add a contact > save and quit
Save the partner

Before this commit, there was a traceback, because a check on parent_id was done to compute
the modifier readonly of the city fields in subviews

However, python onchange gets rid of parent_id because child_ids and parent_id are two faces of the same coin
And if that check were not done, we would end up in an infinite recursion

After this commit, there is no traceback, as we stop checking on parent_id in the case of paged subviews
(list and kanban) because we literally know there is one

OPW 1886320

closes odoo/odoo#27114
2018-11-14 08:33:23 +00:00
Goffin Simon 6123cc912c [FIX]purchase_requisition: Creating requistions from OP
Steps to reproduce the bug:

- Create a product : stockable + purchase : propose a call for tenders + reordering rule (qty min 0, max 0, multiple 1)
- Create a SO for that product.
- Run the scheduler once : a requistion is generated (Purchases > Purchase > Purchase Agreements), which is normal behavior
- Run the scheduler a second time

Bug:

A new requistion was generated for the same product, by the same reordering rule

opw:1892950

closes odoo/odoo#28611
2018-11-13 15:08:20 +00:00
Nicolas Martinelli da2d415b79 [FIX] sale: date on Sales Analysis
Use a consistent date between both views of the Sales Analysis report,
otherwise switching from one view to another shows a different
information.

opw-1903091

closes odoo/odoo#28625
2018-11-13 12:56:57 +00:00
Julien (juc) Castiaux 1767f2186d [FIX] delivery: useless conversion to company currency when no company
After removing the company from a delivery method, every checkout done
in website fails due to odoo trying to convert the price to the
company currency.

This PR fix the bug by doing the conversion only when there is a
company set on the delivery method.

opw-1905466

closes odoo/odoo#28626
2018-11-13 12:57:52 +00:00
Christophe Simonis 4a26aa22e5 [FIX] stock: duplicated xmlid
Half-Cherry-Pick of e9fc0e2b5a

closes odoo/odoo#28629
2018-11-13 13:12:22 +00:00
GabbasovDinar 127c6d1f0d [FIX] check mp_dirty to avoid repeated rendering
The patch fixes the issue related to repeated orderline rerendering. It means
that if products of the order were printed before, those will not be rendered
again when new updates of order is sent to the kitchen.

Closes #28577
2018-11-13 11:29:31 +01:00
Sebastien LANGE 0a6a1c149d [FIX] stock: readonly on show details operations
commit c6b0d36622 introduced a wrong
domain. The readonly should be added if the show_operations is false
OR state is done AND is_locked is true.

close #28595
2018-11-13 09:00:42 +00:00
Duc Dao 46b296dc4f [FIX] Update required version of num2words to have more languages
closes odoo/odoo#25982
2018-11-13 02:22:39 +00:00
Lucas Perais (lpe) 3a0f9da0eb [FIX] web: load SubViews without previous' view _view_ref context keys
On a form view (of model A), define a many2one (model B) with a [form|tree]_view_ref context key
In that view, have a x2m field (model C) with a different [form|tree]_view_ref context key

Before this commit, the second load_views (i.e. on the model C) crashed because
the wrong context key was sent to the server, which returned the view to which the _view_ref points
i.e. the view of the model B

After this commit, we clean the context of subviews loading, because those keys are only useful for the python
and one shot. Hence, there is no crash

OPW 1903780

closes odoo/odoo#28260
2018-11-13 09:02:24 +00:00
Nicolas Martinelli 1a0f5a50af [FIX] account: domain on reconciliation model
The `context.company_ids` variable seems mostly empty in the case of the
Manual Reconciliation widget. Therefore, we fetch the current company of
the user in the session.

Complement of e5c8071484

Fixes #28270
opw-1904475

closes odoo/odoo#28541
2018-11-09 16:14:33 +00:00
Lucas Perais (lpe) c8133d7133 [FIX] calendar: activity deadline from event date
Be in the timezone Australia/Brisbane

On an object, create a Meeting activity

Create the calendar event and set a start date "tomorrow" at 7:00am

Now go back to the object to see the activity

Before this commit, the activity appeared as due "today"

After this commit, it is due "tomorrow"

OPW 1891110

closes odoo/odoo#28576
2018-11-12 12:48:07 +00:00
Nicolas Lempereur bba78c7fe1 [FIX] web_editor: can't unquote on firefox
Firefox when asked to block format (formatting over a block with
blockquote, h1, ...) has a special case for blockquote (it is documented
in https://developer.mozilla.org/docs/Web/API/Document/execCommand at
formatBlock command) and will wrap any element instead of replacing
existing block formatting.

Thus the code not expecting it was not able to remove a blockquote in
firefox once introduced.

opw-1903735
closes #28587
2018-11-12 14:48:20 +00:00
Nicolas Lempereur e0b906d74d [FIX] web_editor: firefox ctrl+a and un/format
When we for example do ctrl+a in firefox, the selection is over the
container and not the content.

This is an issue when we apply a format, since the container could be
removed.

  eg:

  we have selection over `<pre>hello</pre>`, on firefox the selected
  node is `pre`, on chromium it is `TextNode "hello"`.
  if we remove the style, `pre` is deleted so firefox selection is
  broken, whilst chrome has no issue since "hello" still exist.

There was also an issue when the selection was over the blockquote,
there was no error but the style could not be removed.

opw-1903738
opw-1903735
closes #28369
2018-11-12 11:22:43 +00:00
Odoo Translation Bot 8d77288a8c [I18N] Update translation terms from Transifex 2018-11-11 03:16:11 +01:00
Sainu Abideen 79e8378518 [CLA] update cybrosys signature
Was signed with the wrong name

closes odoo/odoo#28496
2018-11-09 14:57:37 +00:00
Nicolas Lempereur 5f066552c3 [FIX] website_form: custom file -> mail attachments
There was a code that on:

- a form that sent a mail
- with a custom file field

would set the file as attachments, but the code was dead because of a
typo in `if` statement order.

opw-1906883
closes #28525
2018-11-09 11:09:32 +00:00
Nicolas Lempereur 726bc301cf [FIX] web_editor: don't prepend http to ${..} link
In mail template a link with reference such as:

  ${object.user_id.signup_url}

are often used.

These are template directives that are replaced when the mail is saved,
so when editing in the editor and they are prefixed by "http://" this
breaks the link which is not wanted.

Now link beginning with `${` are not prefixed anymore to prevent
shooting oneself in the foot.

opw-1906695
closes #28522
2018-11-09 10:45:17 +00:00
Josse Colpaert 0b586677e2 [FIX] sale_margin: Error in Margin calculation
If cost(purchase_price) was 0, margin calculation was incorrect.
The function _product_margin didn't consider the use case
where the cost of the product was set to 0 on the line.

So before the fix it fallback on standard price instead of considering  a cost of 0.

opw:1890452, 1885587
2018-11-08 13:10:10 +01:00
Pierre Rousseau 6e457c44dd [FIX] google_calendar: broken documentation link
The previous link did not contain the version. The default version (12.0) was added, which resulted in a 404 error.

opw-1904268
2018-11-08 10:12:28 +01:00
Sylvain Van Hoof 9b16af6a4b [CLA] sign CLA for Okia SPRL
Backport of 12.0 signature that was done at ff83dfbb60ce

Closes #28493
2018-11-08 10:02:44 +01:00
Christophe Monniez 055e1b8324 [REM] packaging: remove useless code
PKG-INFO is generated during the setup phase and is not needed anymore.
Also this file contains outdated informations.

py2exe is not used anymore to build the windows installer.

closes odoo/odoo#28494
2018-11-08 08:50:33 +00:00
Nicolas Lempereur fc70c35195 [FIX] mail: enable composer after message sent
c5dc0b2f39 disabled send button on composer sent.

But this is only needed for chatter composer, other composers directly
send the message and are not refreshed asynchronously.

So for other composer, the send button worked one time but then was
disabled and the only way to sent was ENTER (on basic composer) or
CTRL+ENTER (on extended composer).

With this fix, disabling the button is done only for chatter composer.

11.0 backport of 12.0 #28474

issue found when checking opw-1904029
closes #28506
2018-11-08 13:19:19 +00:00
Christophe Simonis 190b522e03 [MERGE] forward port branch 10.0 up to e6ff16cbba 2018-11-07 18:25:31 +01:00