Commit Graph
102957 Commits
Author SHA1 Message Date
hendrikw25 c8bf71cf9e [CLA] signature for hendrikw25
Done at #15261
2017-01-30 08:58:13 +01:00
Odoo Translation Bot 1eb9dc79f5 [I18N] Update translation terms from Transifex 2017-01-29 00:30:57 +01:00
Olivier Dony b0c2adbccb [FIX] config: correctly bootstrap data_dir
Complements the patch in 4715d18e12
in order to properly bootstrap a writeable data_dir when it is
(partially) nonexistant.
Depending on the startup parameters the data_dir might otherwise
have ended up read-only, preventing the creation of its necessary
components (session store, file store). Only the `addons` directory
of the data_dir needs to be read-only by default.
2017-01-28 01:53:54 +01:00
Diep Huu Hoang dff352acdb [FIX] point_of_sale: prevent losing orders when validating during sync
When validating a new order in between the create_from_ui RPC call and
the corresponding callback this new order was lost. There were two
reasons for this.

First of all, the Mutex supposed to prevent multiple create_from_ui RPC
calls from happening at the same time did not return a Deferred. This is
problematic because this function gets passed to jQuery.when() which
will consider functions that do not return a Deferred to be resolved
upon return.

Secondly, the resolved callback of the create_from_ui RPC call naively
deleted all paid orders, assuming they were all successfully sent to the
backend. This is not the case when an order is added to the orders array
in between the RPC call and the callback.

Closes #15190
2017-01-27 16:12:36 -08:00
David Halgand e366ee3542 [CLA] corporate and individual signature for halgandd
Done at #14155
2017-01-27 17:17:12 +01:00
Simone Orsi 81dab1e6dd [CLA] add simahawk to C2C CLA
Done at #15250
2017-01-27 16:28:48 +01:00
qdp-odoo 838beb12de [FIX] account: full reconcile sequence has to be shared among companies.
Otherwise, only the main company can make a full reconciliation
2017-01-27 16:05:00 +01:00
qdp-odoo c528f7aff6 [FIX] account: grouping by line should take into consideration the applied taxes 2017-01-27 16:05:00 +01:00
Christophe Simonis 7c9ad40e0a [MERGE] forward port branch saas-6 up to f8b82bdd63 2017-01-27 15:15:46 +01:00
Christophe Simonis f8b82bdd63 [MERGE] forward port branch 8.0 up to f431cee99a 2017-01-27 15:11:53 +01:00
Olivier Dony 6edb749534 [FIX] web: provide correct autofill browser hints
Modern browser implement the autofill specs as described at
 https://html.spec.whatwg.org/multipage/forms.html#autofill

This means that there is now a way to tell the browser when a password
field is supposed to be filled with the user's own password (e.g. on a
login field), and when it's supposed to be used to input a new secret
value (e.g. when changing someone else's password).

This can be distinguished by setting the autocomplete attribute
to `current-password` or `new-password`.

In addition, many browsers have decided to entirely disregard the
autocomplete='off' attribute value, because it is felt that using
a secure password manager (as provided by those browsers) is a net
gain for security, allowing users to pick stron passwords.
See also https://developer.mozilla.org/en-US/docs/Web/Security/Securing_your_site/Turning_off_form_autocompletion

Based on this, the framework should generally consider that
password fields in the backend are meant to be used for *setting*
new values (autocomplete="new-password", i.e. no autocompletion!),
whereas the password field on the login page can indeed be autofilled
with the user's current password (autocomplete="current-password").

In addition to making the above changes, this patch also
lets developer specify their own `autocomplete` attribute on
text input fields.
2017-01-27 14:44:36 +01:00
Olivier Dony 484ce05aa0 [FIX] website_sale_options: reallow "quick cart add" on product grid
Rev 0ff26cf7cd disabled this option
because it was causing JS errors, which is not the case anymore.

We now get the expected result:
 - if product has no variants, open quick add modal dialog
 - if the product has variants, open the product page to let
   the user choose a variant

Also fix the bootstrap modal bug that happens when the quick add
modal is opened on a product that is not published (modal appeared
partially transparent and unusable)
2017-01-27 14:44:36 +01:00
Olivier Dony f431cee99a [FIX] hw_escpos: increase timeout for slow matrix printers
Some printers (e.g. matrix/impact printers) may have a hard time
keeping up with the text output, and may trigger timeout errors
because of this, even though they would otherwise produce a correct
result.

Increasing the default timeout to 5s (from the default 1s) should
take care of most slow printers out there.
2017-01-27 14:42:36 +01:00
Olivier Dony af381bf7ec [I18N] base: update PO template for 15583a4 2017-01-27 14:40:34 +01:00
Olivier Dony 92bdc988af [I18N] base: update PO template for 4715d18e 2017-01-27 14:29:13 +01:00
Olivier Dony 15583a4813 [FIX] module: allow disabling 1-click install
As discussed on issue #15225, it should be possible for system administrators
to disable the 1-click installation system.
The plan is to disable the feature by default, but make it relatively easy
to turn on when it is explicitly desired.

1. At the moment we cannot guarantee that all Apps published on the Odoo Apps
   Store are safe. And it is a security risk to let end-users deploy Python
   code on their Odoo servers without requiring any review/deployment by a
   competent system administrator.
   We will work on improving the validation process of the Store, but this
   will require time, and won't probably be a 100% safe process in any case.
2. The one-click install feature is however really useful to help
   non-technical users install Apps, as long as the feature has been
   explicitly allowed by the system administrator. This is a common feature
   in other software suites as well. So we'd like to keep it as an opt-in
   feature.
3. Administrators of multi-tenant servers, cloud hosting services, etc.
   understandably expect to be able to turn off the feature for
   security/control reasons.
4. By turning off the feature by default, but still exposing it in the UI,
   we keep it *discoverable* for users. The error message should be
   helpful to direct users to their sysadmins.
5. By using the permissions of the download folder as a flag for turning
   off the feature, we avoid introducing an extra server parameter.
   The folder is still created (read-only) by default, for the sole purpose
   of making it easier to locate.

Fixes #15225
2017-01-27 13:00:42 +01:00
Olivier Dony 4715d18e12 [FIX] module: allow disabling 1-click install
As discussed on issue #15225, it should be possible for system administrators
to disable the 1-click installation system.
The plan is to disable the feature by default, but make it relatively easy
to turn on when it is explicitly desired.

1. At the moment we cannot guarantee that all Apps published on the Odoo Apps
   Store are safe. And it is a security risk to let end-users deploy Python
   code on their Odoo servers without requiring any review/deployment by a
   competent system administrator.
   We will work on improving the validation process of the Store, but this
   will require time, and won't probably be a 100% safe process in any case.
2. The one-click install feature is however really useful to help
   non-technical users install Apps, as long as the feature has been
   explicitly allowed by the system administrator. This is a common feature
   in other software suites as well. So we'd like to keep it as an opt-in
   feature.
3. Administrators of multi-tenant servers, cloud hosting services, etc.
   understandably expect to be able to turn off the feature for
   security/control reasons.
4. By turning off the feature by default, but still exposing it in the UI,
   we keep it *discoverable* for users. The error message should be
   helpful to direct users to their sysadmins.
5. By using the permissions of the download folder as a flag for turning
   off the feature, we avoid introducing an extra server parameter.
   The folder is still created (read-only) by default, for the sole purpose
   of making it easier to locate.

Fixes #15225
2017-01-27 12:56:14 +01:00
Zakaria Makrelouf b3cd386fca [FIX] l10n_be_invoice_bba: add translated label
Closes #15245
2017-01-27 12:41:29 +01:00
Nicolas Lempereur 0c76ff4846 [FIX] account: modal account.invoice.line form traceback
In some instances we could get a traceback in the form view of an
account.invoice.line object. This is because the `parent` field can be
undefined depending of the way the form view was opened.

For example there can be a account.invoice.line list in a
sale.order.line form and this lead to a product_id with a traceback
capable context.
2017-01-27 09:57:39 +01:00
Goffin Simon a8b1d30fca [FIX] hr: Bank account from employee not loaded on payment on expense
The bank account didn't appear when selecting SEPA credit transfer in ACCOUNTING>PURCHASE>PAYMENTS
to refund an employee. The bank account is taken from partner set  with the field home_address_id.
So the account holder have to be set on the bank_account_id of the employee with the home_address_id.

opw:702881
2017-01-26 17:04:45 +01:00
Nicolas Lempereur cfcc37bca5 [FIX] expression: leaf in o2m with m2o inherits'd field
The reverse field of a one2many could be originating from an
inherits'd field, this was solved in some instance with f5e5bbda.

The issue could still happen in some instances when doing a comparison
of:

- the one2many field to a False value,
- the one2many with a negative operator and an empty set to negate,

With this change, the ORM is used in such a situation.

closes #15234
opw-704962
2017-01-26 16:47:52 +01:00
Adrien Peiffer (ACSONE) 4232a08164 [FIX] mass_mailing: ondelete cascade on transient
The test wizard will be dropped eventually but it is not possible to delete
the mass-mailing before the transient is cleaned too due to the required field.
To make it faster, add a ondelete cascade on the field.

Closes #15217
2017-01-26 10:29:04 +01:00
Aaron Bohy ff613d8763 [FIX] hr: correctly format mention partner suggestions
Rev. 36f6f26 changed the format of the returned list of employees.

Javascript is expecting an array containing the array of employees,
each employee being a dict with keys id, name, email. But from rev.
36f6f26, it returned an array of employees, themselves represented
by an array containing their id, name and email.

As the format changed, the Javascript mention mechanism never used
the prefetched employees, and always fallbacked on an RPC to fetch
suggestions amongs all partners.
2017-01-26 09:44:57 +01:00
Christophe Simonis 3e31dc0ba4 [MERGE] forward port branch saas-6 up to 09f7916f48 2017-01-25 13:04:50 +01:00
Christophe Simonis 09f7916f48 [MERGE] forward port branch 8.0 up to 9d535ee2c7 2017-01-25 12:56:42 +01:00
andreparames 1d089833b4 [FIX] init: enable evented based on socket
Don't enable evented mode unless gevent is enabled.
Previous code was activating evented mode as soon as gevent is imported which
may happen in different scenario but is not enough to assume the GeventServer
is actually running.

Closes #13463
2017-01-24 18:07:38 +01:00
Jairo Llopis 9d535ee2c7 [FIX] mail: check all parameters are set
Since `model` is not a required field, the invalidation may crash when one is
missing.
It should never happen than a mail.message has a res_id but not a model as it
makes no business sence.
However it is possible than a message temporarly misses one of the two, e.g:

```
self.model = False
self.res_id = False
```
will trigger two writes and will crash at the first.

Above code should probably be refactored to have only one write but this commit
fixes a regression introduced at 8f1c2bfc (the above code did not crash).

Closes #15199
2017-01-24 16:56:33 +01:00
sergio 28ec23e828 [FIX] account: fallback on missing template
template contains the mail template to render and is the result of the call to
`self.env.ref('account.email_template_edi_invoice', False)`

If the template does not exists (deleted), template is `None` and the action
rendering crashes.
While it is not recommended to delete master data, it is still possible to use
custom mail templates.

Closes #15204
2017-01-24 16:50:55 +01:00
sergio 333f012e25 [CLA] signature for sergiocorato
Done at #15204
2017-01-24 16:50:39 +01:00
Hoang, Diep Huu b4c3ac8d48 [CLA] signature for anothingguy
Backport of 2cf3381b to 9.0 as expressed in #13971
2017-01-24 16:15:36 +01:00
Stefan Rijnhart d0ea652221 [FIX] portal: set a company for portal without one
The field company_id is not required on the res.partner and is used when the
portal user is created for portal access.
If the partner as no comapny set, the creation crashes (required on the user).

Use system default company, with possibility for overwrite.

Closes #15030
2017-01-24 13:39:47 +01:00
Daniel Dico 94807753e7 [FIX] anonymization: escape table and field names
Same as 1b9d0fa481

Closes #15187
2017-01-24 10:32:03 +01:00
Joren Van Onder 5ce83b872c [FIX] point_of_sale: avoid scrollbar on main window
Scrollbar appeared in Firefox (at least 50.1.0 and up). Related to
depending on non-standard behavior when setting height on a table. For a
detailed explanation see f0eeed93dc.

In this case we can simply ignore overflow on the main POS window since
the height difference introduced is only a couple of pixels.
2017-01-23 17:33:16 -08:00
Joren Van Onder f0eeed93dc [FIX] point_of_sale: scroll contact list in Firefox and Edge
The POS uses tables to do some of it's layout. It also sets 'height:
100%' on a lot of these tables in an attempt to restrict their
height. The CSS standard however defines the height property on a table
as follows:

"A value of 'auto' means that the height is the sum of the row heights
plus any cell spacing or borders. Any other value is treated as a
minimum height." [1]

Chrome and Safari seems to handle this height property in a way that it
does in fact restrict height. The behavior of Firefox and Edge however
is more in line with the spec, and in these browsers table height is not
restricted by this property.

Because of this the contact list was not scrolleable in those
browsers. To resolve this we stop relying on non-standard behavior by
displaying the relevant contact list elements as regular block
elements. Additionally, we now have to recompute the height of the
client list whenever we show/hide the client details, something that
wasn't necessary before.

[1] https://www.w3.org/TR/CSS21/tables.html#height-layout

Fixes #11020
2017-01-23 12:09:27 -08:00
Joren Van Onder cb597806ec [FIX] point_of_sale: force numpad to appear next to actionpad
The sizes of these UI elements are all fixed and non-responsive and
everything is supposed to fit. Currently however Firefox (at least
50.1.0 up to nightly 53.0a1) is computing the width of a <br> element to
be 0.0166626px, forcing the numpad to wrap to the next line. This forces
the numpad to be 216px wide (width of 4 buttons at 54px each).
2017-01-23 12:04:10 -08:00
Denis Ledoux de6c4f7037 [FIX] project: website live chat link in the planners
These links are links to the Website live chat app description,
not our actual livechat support.

Besides, we currently do not make support through the
livechat.

opw-705614
2017-01-23 17:32:44 +01:00
Daniel Dico 1b9d0fa481 [FIX] anonymization: escape table and field name
to avoid postgresql reserved keywords.
fields like fetchmail_server.user or mail_mail.references uses reserves keywords and must be escaped

Closes #15177
2017-01-23 17:28:16 +01:00
Odoo Translation Bot c9c9c1a755 [I18N] fetch missing terms in previous pull
Due to --the minimum-perc rule on tx
Fixes https://twitter.com/bealdav/status/822110096171954176
2017-01-23 15:58:56 +01:00
Christophe Simonis 0997a1cf6d [MERGE] forward port branch saas-6 up to 5065f4b3e8 2017-01-23 13:14:51 +01:00
Christophe Simonis 5065f4b3e8 [MERGE] forward port branch 8.0 up to 91f11f8bd6 2017-01-23 10:46:39 +01:00
Jeremy Kersten a307ab8076 [FIX] website_sale: partial revert of 6b87284f
This commit has been forward-ported by error in 9 and +.
Update website_sale.js to fix impacted databases.

Decimal precision in v8 = 0.01, and v9+ = 2

With fwd port, int(0.01) instead of int(2) because data-precision
appears 2x, first with 0.01 (v8), secondly with 2 (v9+).

Js fix uses the last decimal-precision (v9) instead of the first (v8)
2017-01-23 09:52:47 +01:00
Nicolas Martinelli 49f5aef548 [FIX] stock_account: inventory at date
The "Inventory at Date" has several issues:
- graph and pivot views are not available despite their existence
- the views are not linked to an action, thus it is impossible to save
  it on the dashboard.

opw-703649
2017-01-23 09:19:49 +01:00
Nicolas Martinelli 68dd9bdb0a [FIX] board: prevent crash if no action
If the user tries to save on the dashboard a view which was not open
through an existing action, the call to method `add_to_dashboard`
crashes because of incorrect arguments (`action_id` is undefined in JS).

This is for example the case when trying to save an "Inventory at Date"
in the dashboard (will be fixed in a subsequent commit).

opw-703649
2017-01-23 09:19:49 +01:00
Odoo Translation Bot 91f11f8bd6 [I18N] Update translation terms from Transifex 2017-01-22 03:25:31 +01:00
Odoo Translation Bot 4169049263 [I18N] Update translation terms from Transifex 2017-01-22 00:39:31 +01:00
Odoo Translation Bot c150838bb5 [I18N] Update translation terms from Transifex 2017-01-19 17:28:33 +01:00
Martin Trigaux 3c9937388d [FIX] website_customer: filter on correct field
The field tag_ids has been removed at df2bed3c but not changed in the controller
2017-01-19 17:17:42 +01:00
Nicolas Lempereur b9db65aa73 [FIX] web: display warning message for o2m modal
Be a little less strict when not showing o2m list view warning so if the
o2m is not editable (a modal is open instead of editing inline) we still
show warnings.

Also have warnings over modal overlays so they can be used for modals.

opw-702333
2017-01-19 16:46:33 +01:00
Nicolas Martinelli 586496338b [FIX] account: crash when unlink taxes
If `get_default` returns an empty value (`None`), the `set` instruction
crashes.

Backport of 26d1a3884b

Closes #15116
opw-702597
2017-01-19 10:51:05 +01:00
Zakaria Makrelouf 050c06188b [CLA] Signature for zakiuu 2017-01-19 10:49:23 +01:00