Commit Graph
110108 Commits
Author SHA1 Message Date
Gert Pellin 4629a4fb0e [FIX] point_of_sale: traceback on printing android
Firefox for android gives atraceback when clicking the print receipt
button. This traceback is caused becaus Firefox for Android does not
support printing.

This fix replaces the traceback by an explanation why it is not possible
to print.

Also  backport for safari-fix

closes odoo/odoo#28919
2018-11-21 15:35:39 +00:00
Dharmraj Jhala 2643e851aa [FIX] website_sale: prevent update of cart qty in edit mode
/!\ Should not be forward-ported in *12.0* /!\

Because of the mechanism to bind change / click event in the 10.0
implementation, when we are in edit mode on a product page, the event
handlers that are in charge of updating the cart quantity can still be
triggered.

After this commit, click / change event while updating cart qty will
not be effective in edit mode.

task-1825889
Closes https://github.com/odoo/odoo/pull/24211

closes odoo/odoo#29224
2018-12-04 09:54:20 +00:00
Sylvain Van Hoof e467681cfd [FIX] delivery: consistent return type
The original method `put_in_pack` returns a `stock.quant.package`.
Therefore, the override should do so.

Fixes #27636
opw-1912671

closes odoo/odoo#29229
2018-12-04 08:35:10 +00:00
Nicolas Martinelli e9bc13fce9 [FIX] website_sale: price difference
- Create a product A with a sales price of 40
- Create a pricelist where product A costs a fixed price of 100
- Assign this pricelist to a customer
- Connect as the customer on the eCommerce

On the eCommerce, the price for A is displayed as: ~~40~~ 100.

We only display a price difference if the pricelist price is smaller
than the sales price.

opw-1885443

closes odoo/odoo#29141
2018-11-30 08:39:37 +00:00
Odoo Translation Bot 536cd8caea [I18N] Update translation terms from Transifex 2018-12-01 02:45:01 +01:00
Nicolas Martinelli ae4a4cf0a9 [FIX] report_intrastat: product weight
- Create a product with 2 variants A & B
- Set a weight on the variants (btw, the weight field is not available
  on the template in this case)
- Create an invoice for A, validate

On the intrastat report, the weight remains 0.0.

The report clearly takes into account the weight of the template, not of
the variant. We use the product weight, and fall back on the template
weight.

opw-1913305

closes odoo/odoo#29178
2018-11-30 09:55:38 +00:00
Nicolas Martinelli 80a11ca27d [FIX] report_intrastat: discount on invoice
- Create an invoice with a discount
- Validate
- Open the Intrastat report

The discount is not taken into account.

opw-1913155

closes odoo/odoo#29161
2018-11-29 17:00:36 +00:00
Richard Mathot 1d553eea7b [FIX] models.py: log the full traceback when record import fails
Without the full stack trace, it is very hard for the developers to know
why and where the record creation has failed.

closes odoo/odoo#29143
2018-11-29 15:12:59 +00:00
Ravi Gohil 8a18ef0c5a [FIX] base: allow property field to be set to False
closes odoo/odoo#29147
2018-11-29 13:46:54 +00:00
Raphael Collet 42c42832b3 [FIX] base: translations lost after synchronization
Modifying a source term in an XML/HTML translated field can lose translations
if the same term is translated in several languages.

closes odoo/odoo#29078
2018-11-27 16:07:46 +00:00
Martin Trigaux 5472bbded5 [FIX] mail: invite: use proper translation terms
Fix translation placeholders in invite wizard, to make them easier to
understand for translators. Also rework the message generation code
to ensure proper XML structure.
2018-11-03 16:47:43 +01:00
XavierDo 9043305fa0 [FIX] mail: verify attachment access early to avoid errors later 2018-11-02 11:23:10 +01:00
Denis Roussel 6639630de1 [FIX] base: make check_credentials more consistent with alternatives
The other methods do test password length before verifying it, so even
if check_credentials() is not meant to be called directly, it's better
to keep it consistent with the alternatives.

Closes #29023
2018-11-27 10:14:43 +01:00
Olivier Dony 3b85900faf [DOC] install: update info about wkhtmltopdf
We now support version 0.12.5(.1), which is available for all recent Debian and Ubuntu versions,
and contains quite a few bug fixes. An up-to-date version of Odoo 10 or later is required, for
pixel-perfect compatibility with the result of 0.12.1.3.
See also the wiki for more info: https://github.com/odoo/odoo/wiki/Wkhtmltopdf
2018-11-26 13:40:15 +01:00
Denis Ledoux af476c6949 [FIX] report: support for wkhtmltopdf 0.12.5
This revision brings the compatibility for our reports
using wkhtmltopdf 0.12.5.

Up to now,
the supported wkhtmltopdf version was 0.12.1.

The goal of this revision is to add the compatibility
to wkhtmltopdf 0.12.5,
while keeping the same exact rendering than in 0.12.1.

There is a behavior change with the `--dpi` parameter,
which no longer has a "zoom" level effect as it did with 0.12.1.

To deal with it, we pass the `--zoom` parameter when
the detected version installed of wkhtmltopdf is after 0.12.2,
with a ratio 96:dpi. 96 being the default dpi of wkhtmltopdf.

This trick allows to render the reports with the exact same
zoom level, whatever the dpi value configured in the reports paperformat.
(at least with dpi values up to 149, after 150, included,
the dpi parameter with wkhtmltopdf 0.12.1 as a weird behavior,
it no longer zoom out)

opw-1907346

closes odoo/odoo#28864
2018-11-21 09:30:02 +00:00
Nicolas Lempereur 1f8788deef [FIX] purchase: es_AR translation typo
Fixing it directly by commit since there is no es_AR on transifex.

The issue of the ticket has been solved by transifex, this is for
another similar issue that has been found.

opw-1907924
closes #28923
2018-11-21 17:37:35 +01:00
Denis Roussel e81809b89d [FIX] mrp: Allow mrp user to delete stock_move_lot links
With an mrp user, add lots lines to mrp production order moves. Then,
try to delete one line, the dustbin icon does not appear.

opw-1908930
2018-11-21 14:08:47 +01:00
Denis Roussel 8a6162d00d [FIX] mrp: User with no products write access cannot create production order
As the product_tmpl_id field is related one but not readonly, the creation
of production order triggers a write on product.product model
2018-11-21 13:16:45 +01:00
Nicolas Lempereur 258eaa7a3c [FIX] web_editor: firefox `´ accent no break position
On firefox if we do for example:

ALT+GR + [ALT+GRable ´ key]

Firefox may send keys "AltGr" and "Dead" instead of just "AltGr".

This was possibly causing caret to go a position too low when writing
speedily with diacritical marks.

opw-1903865
closes #28739
2018-11-15 16:52:31 +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
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
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
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
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
Yenthe V.G e6ff16cbba [FIX] sale: fix type of created invoice from SO
Consider the generation of an invoice for a SO having the following lines:
quantity | unit price | taxes | subtotal
----------------------------------------
       1 |        100 |   15% |      115
       1 |       -110 |       |     -110

Previously, the invoice wrongly received the type 'out_refund' instead of 'out_invoice'. This was because the code was only considering the untaxed amount.

Closes #28259
Fixes #26726

Co-authored by pedrobaeza
2018-11-07 13:08:57 +01:00
Pierre Rousseau df057df5a9 [CLA] Signature for Ugaitz Olaizola
opw-1895508
2018-11-07 11:03:13 +01:00
Goffin Simon d2cd181abe [FIX] mrp: Bom Cost with variants are not displayed properly
When making a BOM with variants, printing the Bom Structure didn't
display the complete name of each variant.

opw:1902770
2018-11-06 10:31:57 +01:00
Laurent Smet 081e1de879 [FIX] account: Fix multi-company/currency in Aged Partner report
This code is called by account_reports to build the Aged Receivable/Payable.
However, no support for the multi-company/multi-currency is there and then,
the multi-company filter on account_reports never worked.
2018-11-05 16:48:33 +01:00
Andrea Stirpe 5de5953ae7 [FIX] account_asset: domain in multicompany
In a multicompany environment, an user who has access to multiple companies is
able to select accounts and analytic accounts of multiple companies. This can
easily lead to mistakes in the definition of the asset category.

With this commit the user can only read/select accounts and analytic accounts
belonging to the company already set in the asset category.

This is what is already done in most invoice or other accounting views

Closes #26578
2018-11-05 16:23:10 +01:00
mreficent 9c7043d235 [IMP] account: test data: don't define any currency on test bank journal
The constraint introduced in https://github.com/odoo/odoo/commit/22f0da809e84618901b7ca4b78582abd64c03c55 raised in case the currency of the company loading the test data was also USD.
2018-11-05 15:33:10 +01:00
Andreas Perhab d3b86ab930 [FIX] purchase_requision: fix syntax error
payment_term.id, creates a tuple wich works if payment_term.id is set
in case payment_term.id is False this creates the tuple (False,) which
is then converted by the Odoo ORM to a account.payment.term(False, )
record set, which in term may cause weird behaviour as this value does
not eval to false in cases like `if self.payment_term_id:`

Closes odoo/odoo#28397
2018-11-05 13:06:33 +01:00
Olivier Colson 053a023fc7 [FIX] account: apply correct currency rate for taxes at account move creation
Before that, taxes were only applied with the most recent currency rate, which caused problems in multi currencies, when reconciling statement lines made in the past with invoices, causing the amount currencies in the payment account.move to be wrong.

//Scenario to reproduce the issue (from customer ticket 1903497):

(for a company with USD as base currency)

1. Create a new bank journal for EUR payments

2. Create a new customer invoice for 90€

3. Create a new tax for the reconciliation model, price-included and amounting to 15%

4. Create a new reconciliation model using this tax

5. Use the currency rates from the demo data, add one that is closer to current date than the most recent one.

6. Create a new bank statement for the created EUR bank journal. Make sure that the transaction is less than the actual amount due on the invoice so that we can apply the reconciliation model. Also make sure to set a date on the transaction that lies in the past at some point when the currency rate was (significantly) different.

7. Hit the reconcile button, select the amount due from the invoice and apply the discount reconciliation model(take note of the amount on the created tax move line). Now reconcile.

What is the current behavior that you observe?

Now go back to the bank statement and check the created journal entries. You will see a difference in the amount currency values of the payment and the tax account move line. This difference should not exist.
2018-11-02 17:25:44 +01:00
Nicolas Martinelli bbeb126cf8 [FIX] sale_timesheet: UOM
Revert commits da2140b726, e65c8826ef and 06cd145a79. They
introduce an incorrect UOM.

The original issue was an `AccessError` due to the fact that the
employee chosen was not in the same company than the user. Therefore,
instead of changing the logic of the UOM selection, we make sure to
select the employee in the appropriate company first, then fall back on
any company then.

opw-1888299
2018-11-02 13:48:05 +01:00
Yoshi Tashiro 09a81894b1 [FIX] product: respect received args value instead of overriding it (#26594)
When doing a name_search, if a current search is already specified through args,
do not replace it

Closes #26594
2018-11-02 13:38:11 +01:00
Yoshi Tashiro 7d2bc7d35a [FIX] website_sale: reset cart if checkout was done in another session
This commit extend commit https://github.com/odoo/odoo/commit/ef48b81ab127dd717a4a9d106edd5c51121bc8f7
When you have a cart on multiple session and confirm the card in one of them,
you could still access your cart from other session (note that you could not do
anything with it as it would be reset when adding product or changing qty).

Closes #28210
2018-11-02 11:10:52 +01:00
Romain Derie 3457d1a74b [FIX] website_sale_options: prevent other session crash after checkout
Check commit https://github.com/odoo/odoo/commit/ef48b81ab127dd717a4a9d106edd5c51121bc8f7

This commit is doing the same for website_sale_option as the optional product
is calling another route to add the product to the cart.
That route needed to be fixed too.

Closes #28209, related to #27508
2018-11-02 11:10:50 +01:00
Odoo Translation Bot e2afb0755d [I18N] Update translation terms from Transifex 2018-11-01 02:44:41 +01:00
Goffin Simon 93d69933ac [FIX] stock: Wrong production/scrap/adjustment location used in multicompany
- When using perpetual inventory valuation, the accounts used for scrap, manufacturing,
and inventory adjustment operations are set on the corresponding locations .
- In a multicompany environment, you will have a separate chart of accounts for each company.
- Account fields on locations are not property fields.
- Therefore, in order to separate the accounting of manufacturing, scrap, and inventory
adjustment operations, you must use a location for each operation for each company.
- Set up one location for each company for scrap, production, and adjustment
locations, setting the company field on each.

Bug:
- When attempting to create a MO, inventory adjustment, or scrap order while signed
in to the second company, you will receive a permissions error on stock.location.

Fix:
- Now the right location is taken according to the company of the user.

Backport of this commit: c7526407ab

opw:1817339
2018-10-31 11:51:09 +01:00
Olivier Dony 9cc8a8d0a4 [FIX] reqs: bump up recommended requests version
In light of CVE-2018-18074, using python-requests 2.20.0 is recommended,
or any distribution-specific version that was patched.

See also https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2018-18074
2018-10-30 18:49:35 +01:00
Martin Trigaux 214975911b [FIX] l10n_ro: fix xml syntax 2018-10-30 18:28:00 +01:00
Duc Dao f978722503 [IMP] l10n_vn: fix syntax and allow reconcilation
for accounts 3341, 3348, 141, 1388, 3388
2018-10-30 18:24:15 +01:00
Raphael Collet 1ca1918a45 [FIX] base: subscribe new API onchange methods for module fields
Adapt the code to use the new API for onchange methods.  This fixes onchanges
for version 11.0, since support of old-API onchange is actually gone.
2018-10-29 14:51:42 +01:00
Olivier Colson ac08e2ba53 [FIX] mail: display both tracking values and body of the messages in mail thread
Before that, the body of the message was never displayed if the message had tracking values. This was annoying for account_asset module, were we prompt the user for some justification when she modifies the depreciation data of an asset, and then call message_post with this text as body, and tracking values reflecting the change that was made.
2018-10-26 11:37:52 +02:00
Josse Colpaert 9647620a91 [FIX] mrp: workorders of sub-BOMs
- Create the following BOM structure:
```
  Prod 1 (Manufacture)
  |
  --- Prod 2
      Prod 3 (Kit)
      |
      --- Prod 4
	  Prod 5
```
- The BOMs for Prod 1 & 3 must have a routing set, to generate
  workorders
- Create a MO for 1 unit of Prod 1, process to the end

2 units of Prod 1 are created instead of 1.

This is due to the WO for Prod 3 not having a `next_work_order_id`.
Therefore, `record_production` adds an extra quantity at:
```
production_move.quantity_done += self.qty_producing
```

To prevent this, we set as `next_work_order_id` of the BOM of Prod 3 the
WO of Prod 1.

Closes #19527
opw-1817398
opw-1883693
2018-10-25 14:58:43 +02:00
Gert Pellin 299c6dd3b4 [FIX] point_of_sale: alignment note textarea
before fix:
in firefox the textarea of note modal has a overflow
textarea can be expanded outside borders modal in all browsers

closes #25199
closes #25215

issue 1895298
2018-10-25 13:22:02 +02:00
Martin Trigaux bfbaa09268 [FIX] hr_attendance: allow multiple attendances
If the search returns more than one result, the rendering of the message would
crash (SingletonError when accessing check_in field value).

Use the same order and limit as both search before and after

Courtesy of David Tran

Closes odoo/odoo#28055
2018-10-25 11:49:15 +02:00
Gert Pellin 8e63bcb47c [FIX] point_of_sale: IoT https in pos
before this fix it was not possible to connect to the pos/iot-box using
https on the pos. By checking if the pos is http or https this is now
possible after accepting the certificate.
if https scanning for proxy is disabled, the user should always give a
    ip in the configuration
2018-10-25 11:33:32 +02:00
xmo-odoo 71cb425d00 [FIX] doc: translator under Sphinx 1.5
In Sphinx 1.5 (fairly specifically), the warner thing takes a `type` kw,
and building the doc blows up if that parameter is not provided.
2018-10-25 11:08:35 +02:00