Commit Graph
114698 Commits
Author SHA1 Message Date
Lucas Perais (lpe) e6cccbf441 [FIX] web: less boolean_toogle
Before this commit, the boolean_toggle widget was rendered
but the less contained errors that prevented it from displaying correctly
This was due to commit 9dead7e3d3

After this commit, the widget displays correctly

There might be an issue in the future because of
field_utils.formatBoolean, when this function decides to pass the full options dict

OPW 80782
2018-02-01 09:32:46 +01:00
Swapnesh Shah c9ef5742bb [FIX] stock: scheduled date required
The field `scheduled_date` on `stock.picking` is used to set the field
`date_expected` on `stock.move`. Since `date_expected` is required, we
should make `scheduled_date` required as well.

Closes #22684
2018-02-01 08:44:48 +01:00
Tomas Alvarez 1d4a75d930 [CLA] add tomeyro to Vauxoo's CLA
Done at #21952
2018-01-31 17:00:01 +01:00
Christophe Simonis 373c0c2e57 [FIX] base: allow server actions to en/decode base64
This is usefull when dealing with binary fields.
This was possible in previous versions in python 2 using
`str.encode('base64')`.
2018-01-31 15:00:25 +01:00
Nicolas Martinelli a4c7481f24 [FIX] web: auto-refresh of time
When a TZ mismatch is detected, the datetime value is displayed in the
widget. However, on MacOS, this forces the dropdown list to close at
each refresh of the value, which occurs every second.

The refresh interval is set to 1 minute in case of MacOS.

opw-804035
2018-01-31 14:40:23 +01:00
Nicolas Martinelli b97b6de12c [FIX] mrp: incorrect help
The help is completely incorrect and misleading.

opw-807178
2018-01-31 14:30:26 +01:00
Nguyen Tan Phuc 00a10fdd00 [FIX] point_of_sale : wrong currency decimals
To have the same behavior as `_compute_decimal_places` in python
When setting rounding of currency > 10, POS will get negative decimals
instead value 0 and crash

Closes #22199
2018-01-31 11:45:31 +01:00
kaberer c07f78db17 [CLA] signature for kaberer
Done at #22641
2018-01-31 09:56:15 +01:00
Lucas Perais (lpe) 8b97a39907 [FIX] mail_template: replace local links except mailto
Before this commit, all the mailto:xx@ww.com in emails were transformed into
http://web.base.url/xx@ww.com

This was due to the url parsing of werkzeug urls.py, which definitely get the scheme
(mailto), but doesn't get the netloc of the url -- because it has no //

Ater this commit, we transform links to local ones, except if the scheme is mailto,
and the issue disappears.

OPW 807795
2018-01-31 09:20:13 +01:00
Nicolas Martinelli c52b18e65f [FIX] account_check_printing: multiple partners
- Create a bill for partner A of an amount X
- Create a bill for partner B of an amount Y
- Validate both bills
- Select both and register a payment by check.

Two payments are created with the same amount in words: X + Y.

In this specific case, we recompute the amount in words automatically.

opw-805842
2018-01-31 09:14:57 +01:00
RomainLibert a5cbf2105c [FIX] resource: _interval_and not working with disjoint intervals
When we pass two disjoint intervals the behaviour of _interval_and is a
little strange, it returns an interval wich begins after it finishes.
In order to fix that we return None when the intervals are disjoint.
2018-01-30 17:38:30 +01:00
Martin Trigaux ed54418d62 [FIX] maintenance: translate team name
If the name of a crm.team is translated, why not the one of a maintenance.team

opw-805838
2018-01-30 14:42:09 +01:00
Martin Trigaux 5ae494f2bb [FIX] stock: more flexible xpath
If you have stock installed before 0322f6e5 and try to install stock_account
today, the installation fails.

Should not rely on a field added after the stable freeze

Fixes #21823
opw-802767
2018-01-30 14:35:25 +01:00
Nicolas Lempereur 109ecd5205 [FIX] web_editor: firefox RTEWidget if hidden
It seems that firefox has some difference of behavior from other
browsers as said in:

- https://bugzilla.mozilla.org/show_bug.cgi?id=548397
- https://github.com/whatwg/html/issues/1813
- https://github.com/w3c/csswg-drafts/issues/571

It seems that at least in one instance (a html field hidden on the pos
configuration), firefox fails because of something similar:
window.getComputedStyle(element) returns `null` instead of the element
styles.

In my tests, using the parent window (possible if current frame and
parent have the same origin which should be the case) worked in this
instance, this is examplified by this jsfiddle:
 https://jsfiddle.net/Lpv898ve/2/

This work with window.parent and not using window directly.

So this commit adds fallback on doing getComputedStyle from the parent
window (when testing on chromium this gave exactly the same result that
before).

opw-813363
fixes #22211
closes #22610
2018-01-30 10:37:53 +01:00
Martin Trigaux 622b1d2370 [I18N] l10n_be_hr_payroll_fleet: export translation source terms
Will not be published on Transifex as for Belgium only

opw-805838
2018-01-30 09:39:08 +01:00
Nicolas Martinelli 14c6968224 [FIX] point_of_sale: data translation
- Create a product with name 'EN' in English and 'FR' in French
- Connect to the POS interface with a user having the French language
  set up.

The product name is loaded as 'EN' instead of 'FR'.

The language is missing from the context of the `search_read` calls.
Therefore, the product names (as well as categories, UOM...) are loaded
in the default language.

opw-805431
2018-01-30 08:53:58 +01:00
Martin Trigaux 76840643ad [I18N] sale: export source terms
Some where missing, followup of opw-805838
2018-01-29 16:30:47 +01:00
Martin Trigaux b0ce9ce8ca [FIX] hr: open in list view
This action was not working as the tree view has been removed
This feature was replaced by hr_org_chart module
Just display a list of the employee and subordinates

Fixes #20203
Fixes #22312
Fixes #22536
2018-01-29 16:26:21 +01:00
Olivier Colson 75857a2c34 [FIX] account: don't ignore default journal_id in payments' onchange on amount field
onchange function getting called when modifying the 'amount' field of account.payment always changed the journal of the payment when this amount was equal to zero. This caused a bug with batch deposits, when trying to create a new payment from the tree view contained in the form view of account.batch.deposit: passed default value for journal_id was ignored.
2018-01-29 14:42:36 +01:00
Nicolas Martinelli 6a91ae0c18 [FIX] event: mail after event
Prevent sending emails that were scheduled before the event to be sent
after the end of the event.

opw-802973
2018-01-29 13:53:40 +01:00
Christophe Simonis 9af65a7efe [MERGE] forward port branch saas-16 up to 0b188b5804 2018-01-29 13:37:12 +01:00
Christophe Simonis 0b188b5804 [MERGE] forward port branch saas-15 up to 2629029d03 2018-01-29 13:29:14 +01:00
Christophe Simonis 2629029d03 [MERGE] forward port branch saas-14 up to 8b8f04e14c 2018-01-29 13:28:18 +01:00
Christophe Simonis 8b8f04e14c [MERGE] forward port branch 10.0 up to 6d682cea25 2018-01-29 13:27:28 +01:00
tbe-odoo 6d682cea25 [REV] http: Implicit session deactivation -> Explicit destruction
- This commit degrade the performance and introduce a bug for multiple database servers.

This reverts commit bc69b47073.
2018-01-29 13:25:21 +01:00
Nicolas Martinelli 8ed7570b1c [FIX] tools: float_round DOWN
The result of the following:
```
float_round(2.5, precision_rounding=0.05, rounding_method='DOWN')
```
is 2.45. Instead, 2.5 is expected.

In case of the `DOWN` method, epsilon should be added, not subtracted.
In the meantime, we introduce a slight reorganization of the method to
make it clearer.

opw-805008
2018-01-29 11:06:33 +01:00
Martin Trigaux 43bf9ff29d [IMP] sale: display which field was actually modified in the error message
Was previously displaying the whole list of fields
In error such as #22333 the error was not clear which field is nodified
2018-01-29 10:03:54 +01:00
Yenthe V.G 74c91f4afe [FIX] doc: typos
Closes #22341
2018-01-29 10:01:42 +01:00
Lucas Perais (lpe) af17cd76e4 [FIX] account: onchange payment type to internal displays all journals
on account.payment, when changing the payment type to Internal Transfer,
the result of the onchange was erroneous as inbound and outbound methods
lack relevance in that case
After this commit, We choose to display all bank and cash journals in this case

OPW 804214
2018-01-29 09:29:24 +01:00
Rémi Rahir 4669a4a91f [FIX] iap: account link not wworking in saas
Before this commit, the dashboard pill taht allows the user to consult
his iap accounts was hidden for saas users as it is grouped with the
app store and theme buttons which are not supposed to be shown since
they are not available in saas.

This commit ensures taht the button will be shown both on saas and premise instances.
2018-01-28 16:32:14 +01:00
Odoo Translation Bot 53c9858656 [I18N] Update translation terms from Transifex 2018-01-28 04:29:24 +01:00
Odoo Translation Bot e8d719e977 [I18N] Update translation terms from Transifex 2018-01-28 00:43:32 +01:00
Christophe Simonis bcf6529755 [MERGE] forward port branch 10.0 up to 8e38a3d069 2018-01-26 16:06:51 +01:00
Martin Trigaux 843115ed8c [IMP] doc: rename page, add link 2018-01-26 15:58:28 +01:00
Pierre Rousseau 86adba1599 [FIX] sms: send sms in list view 2018-01-26 15:33:54 +01:00
Nicolas Lempereur 94ed561830 [FIX] website_sale: css ... alternative products
In the alternative products with 66994856 the thumbnail blocks were
restricted in size.

This is not very nice in the basic theme (the text of a product is cut
unexpectedly by the block border) but seems outright wrong on other
theme without border.

This commit forces the alternative product name to be on only one line
and be ellipsed. There was a lot of possible solution but for supported
browser compatibility and not breaking possible existing customization,
this one was choosen.

A better solution would probably use "flex" but we can't use it
currently (because of internet explorer support).

opw-806285
closes #22547
2018-01-26 14:37:54 +01:00
qsm-odoo 94c954121e [FIX] mass_mailing: lower the risk of messing with the mail wrapper
Mail content is wrapped in a table to properly allow centering the
layout in all mail clients. The problem was that this table was able
to be customized by the editor while it should not.
2018-01-26 13:31:36 +01:00
Christophe Simonis 8e38a3d069 [MERGE] forward port branch 9.0 up to ea879956b1 2018-01-26 13:17:23 +01:00
Christophe Simonis ea879956b1 [FIX] pad: allow to create records with unknown fields 2018-01-26 12:44:18 +01:00
Jairo Llopis 055bac5fcc [FIX] website: Form editor addon is enterprise
Introduced at f90290d1

Closes #22370
2018-01-26 11:09:46 +01:00
Nicolas Martinelli 927e13436a [FIX] account: duplicated field
`currency_exchange_journal_id` was duplicated due to forward port.

opw-807839
2018-01-26 09:11:49 +01:00
Christophe Simonis 9620989501 [MERGE] forward port branch 9.0 up to 222cadda41 2018-01-25 20:24:39 +01:00
Christophe Simonis 222cadda41 [FIX] base: sort ir.actions.act_window.view records deterministically 2018-01-25 20:20:09 +01:00
Nicolas Lempereur 3afe5b6508 [FIX] hr_timesheet: allow duplication of project
When duplicating a project, a command [(6, _, ids)] may be generated.

This fail with the commit aa8a39fc4f because all comodels records with
id not in `ids` will have their inverse field unset.

But eg. in the case of copy, this would trigger an error because this
would be done to an empty recordset and unexpectedly trigger an error.

opw-807655
closes #22525
2018-01-25 17:57:37 +01:00
Nicolas Martinelli 842e02020b [FIX] purchase: change invoice date
- Main currency: USD
- Create a PO in EUR
- Create an invoice from the PO
- The invoice is in USD and the exchange rate is applied
- Change the currency to EUR

The conversion is not applied anymore.

The original issue was that changing the date would overwrite any amount
modified in the invoice. Actually, the dependency on the date is not
really necessary. Indeed, this is supposed to help enconding invoices,
but it is likely that:
- If the PO is issued in a currency A, the bill received is in currency
  A.
  => no conversion necessary (solved from 11.1).
- If the PO is issued in a currency A and the bill received is in
  currency B, the exchange rate used by the vendor is different from
  ours.
  => manual corrections are necessary

Therefore, we remove the dependency on the date for the amount
recomputation. However, we still use it in the onchange. This way:
- the amount estimated should be close to the amount requested
- we avoid unexpected recomputation of amounts

Introduced with d8112b0238.

opw-805926
2018-01-25 17:04:33 +01:00
Géry Debongnie 21c1b1acd3 [FIX] web: add target=_blank to url field widgets
Url in the web client are supposed to open in a new tab.  This was the
way it worked in v10.0 and was lost with the refactoring of the new
views.

We just reintroduce that behaviour with this commit.

Closes github issue #22389
2018-01-25 16:31:06 +01:00
Nicolas Lempereur b27abee396 [FIX] web_editor: ready when translations ready
$('web_editor.base').ready() returns a deferred that:

- wait at least for $(document).ready()
- wait at least for require('web.ajax').loadXML()
- at most once starts translations configuration

But there is an issue since there is unexpectedly no reference to the
translations, whilst it should have also been ready when ready was
resolved.

This commit keep the reference so translations can be used after
$('web_editor.base').ready() is resolved as it was before 7dfdfa0103.

note: in 11.0 it should be solved with 29729769 (so fix is for [10,11[)

opw-804148
closes #22522
2018-01-25 15:58:32 +01:00
qsm-odoo 25849e9186 [FIX] web_editor: properly allow formatting text (normal/header 1/...)
Sometimes the formatting buttons had no effect or formatted more than
they should (like a whole column when triple clicking on a paragraph
only). This was because of the `listBetween` function implementation.
This is supposed to return all the nodes between one element and another
one... but the logic is wrong without saying from which *point* to start
and which *point* to end. For example, when asking the list between an
element and its parent, the result is very wrong as there is no way to
go from the beginning of an element to the beginning of its parent using
the `walkPoint` function as the `listBetween` function is doing.

Ideally, the function should be entirely fixed but this can be tricky.
For now, the function is just extended to allow to specify points
instead of nodes, and those are used by the `formatBlock` function to
solve the current problem.
2018-01-25 14:36:47 +01:00
qsm-odoo fb81c331f8 [FIX] web_editor: fix double Shift + Enter
Pressing Shift + Enter twice was buggy because of small refactoring
made by https://github.com/odoo/odoo/commit/c227b8fd88e0ed635a8e807501b559b46fee7786#diff-cc5180b5ec2395c1df5c4e475aff43fbL416

opw-806003
2018-01-25 13:58:59 +01:00
Martin Trigaux 7ee7262ccb [FIX] point_of_sale: include untaxed amounts in tax lines
If some orders have no taxes (e.g. manual reimbursement with a negative amount)
the sum of taxes lines gave a different result than the total amount sold.

e.g.:
order 1: price 10€, including 2€ for taxes
order 2: price -5€, no taxes

report:
  taxes:
   20%, 2€ taxes, 8€ base amount

  total sold:
   5€

2+8 != 5

Also change line.price_subtotal as it was computed twice if there was two taxes
on a line (although it will probably never happen in the pos)

opw-805415
2018-01-25 13:53:56 +01:00