Commit Graph
114128 Commits
Author SHA1 Message Date
Nicolas Seinlet 68cb2ade09 [IMP] base_import: defer parent store
Makes possible to choose `defer_parent_store_computation` in UI.

Closes #21320
2017-12-12 12:05:51 +01:00
Simon Lejeune b610e2a812 [FIX] purchase: po line and force_save
Two fiels are set readonly according to the status of the purchase
order: product_id and product_uom_id. They become readonly once the
purchase order is confirmed, but according to the options a user is
still able to add purchase order line. Make sure to always send the
required fields to the server.

Fixes #21519
2017-12-12 10:52:54 +01:00
Pierre Masereel 63b4e2342e [REF] stock: change icon of packages statbuttons 2017-12-11 13:40:47 +01:00
Nicolas Martinelli 4732a16dd1 [FIX] account, project, sale: do not display 'View' button
When adding a partner (without any backend or portal access) as a
follower of an invoice, project, task or SO, the mail received contains
a 'View ...' button. When clicked, it redirects to the login page.

In the case of projects and tasks, no `auth_token` exist, so the user
faces an access error in the backend. For the other objects, it
redirects normally to a frontend page.

This feature is not yet complete in v11. So simply hide the button until
this is properly developed in master.

opw-785824
2017-12-11 12:50:20 +01:00
Xavier Morel 9ad6458241 [FIX] website_twitter: finish P3 migration
I clearly missed some bits in 01e3514147
as _get_access_token was still using urllib.Request despite that
import having been removed.

Fix it up by properly converting it to requests.

Fixes #21544
2017-12-11 11:51:17 +01:00
Adrian Torres b7ce07ad2a [FIX] website, mass_mailing: same field defined twice (#21503)
The ORM does not currently, an probably won't support two fields with
the same name in different modules that do not depend on each other.

This is obviously a nasty hack, but it's the best one can do for a
stable branch.

THIS IS WHY WE HAVE DEPENDENCY MODULES, PEOPLE.
2017-12-11 10:43:48 +00:00
Romain Derie a1c5af2556 [FIX] website_sale_stock: unicode as uom name will throw encode error
Before this commit, if you had an uom with an unicode character as name, it
would throws an UnicodeEncodeError.

Now, since the str() parsing is not needed, removing it fixes the issue

This closes #20325
This closes #21374
2017-12-11 11:24:45 +01:00
Andrea d062e39b1c [REM] hr_timesheet_attendance: remove leftover files
Delete not inmported files. Those are leftover of
removal of hr_timesheet_sheet from
2e251f7599
2017-12-11 11:18:13 +01:00
Abdulmomen Kadum عبدالمؤمن كاظم 15026b8a86 [FIX] base: import translation file
Correctly open file

Closes #21064
2017-12-11 10:09:17 +01:00
Abdulmomen Kadum عبدالمؤمن كاظم e521f43256 [CLA] signature for bluemix
Done at #21545
2017-12-11 10:07:15 +01:00
Odoo Translation Bot 1a43e2e66f [I18N] Update translation terms from Transifex 2017-12-10 04:25:30 +01:00
Nicolas Martinelli 02b9dbac32 [FIX] im_livechat: missing file
`$.position` is defiend in `jquery-ui.js`, which is not included in the
`external_loader` asset.

opw-783901
2017-12-07 15:14:04 +01:00
Raphael Collet 0109c9e063 [FIX] mrp, stock: bad context/domain/attrs in views 2017-12-07 14:21:16 +01:00
Raphael Collet 7b3796d77c [FIX] ir_ui_view: validate contexts, domains and attrs in views
OPW 779494
2017-12-07 14:21:15 +01:00
Can Tecim 88ccc40603 [CLA] Projet Grup signs the Corporate CLA
Done at #21443
2017-12-07 10:30:50 +01:00
Raphael Collet 598d54527a [FIX] base: do not unlink() to remove ir.property records (#21269)
Unlinking such a record causes a cache invalidation, that drops the values of
other company-dependent fields to set.  This may cause other company-dependent
fields to be set to their former value.

OPW 782080
2017-12-07 09:41:28 +01:00
KomarovAlea 1f971ce252 [CLA] signature for KomarovAlea
Closes #21399
2017-12-06 16:13:08 +01:00
Raphael Collet 6da1c3ac4c [FIX] fields: performance of convert_to_onchange on x2many fields
Suppose we convert a x2many field `foo_ids` with a many2one sub-field `bar_id`.
The conversion of the values of `bar_id` generates pairs `(id, name)`.  Before
this patch, the method `name_get` is invoked on every value, one by one.
Rewrite the code to ensure that `name_get()` is invoked on all values at once.
2017-12-06 15:56:25 +01:00
Graeme Gellatly a9a1895b31 [FIX] product: correct seller selection
Choose the date in the user's tz
Compare the quantities using float_compare to avoid rounding issues during UoM
conversions

Closes #21359
2017-12-06 15:54:24 +01:00
Graeme Gellatly b28393487c [CLA] signature for gdgellatly
Done at #21359
2017-12-06 15:54:23 +01:00
Christophe Simonis acff087b01 [FIX] point_of_sale: use defined variable
Oversight of previous forward-port
2017-12-06 12:53:39 +01:00
Nicolas Lempereur b1886ef60e [FIX] google_{account,calendar}: typo PY3 01e35141
When an error happen (which may have been intended as such and ignored
down the error pipeline) in google_account/google_calendar there was
some typos that tracebacked.

opw-783271
closes #21263
2017-12-06 12:40:41 +01:00
Christophe Simonis f96a797fe6 [MERGE] forward port branch saas-16 up to b8540eefe3 2017-12-06 11:59:38 +01:00
qsm-odoo dc5755698c [FIX] web: restore saas modals
This commit basically reverts 4974f8edb7
The fix was unstable (as restoring a feature that was not there
before release, even if originally merged before). This was in
particular breaking saas modals as lots of them are still opened
using 8.0 system... and opening them this way might make them appear
below their own backdrop in the new system the mentioned commit
restored.

We will think about that feature again for a future version.
2017-12-05 18:45:58 +01:00
Goffin Simon c487381dbf [FIX] pos_restaurant: Installing pos_restaurant with demo data
When installing the module pos_restaurant with demo data, the check boxes for
module_pos_restaurant and is_table_management must be checked.

opw:785943
2017-12-05 16:56:30 +01:00
Christophe Simonis b8540eefe3 [MERGE] forward port branch saas-15 up to 970be94f37 2017-12-05 16:46:14 +01:00
Christophe Simonis 970be94f37 [MERGE] forward port branch saas-14 up to e9c2dcd28d 2017-12-05 14:52:16 +01:00
xmo-odoo 96fcd4b56c [FIX] website_sale_stock: don't break product from non-website routes
Fixes #21442
2017-12-05 14:35:31 +01:00
Yannick Tivisse 03375dad3c [FIX] product: Hide product variant field if option not actived
Purpose
=======

If the group_product_variant is not activated, the field should be hidden
2017-12-05 14:26:56 +01:00
Christophe Simonis e9c2dcd28d [MERGE] forward port branch 10.0 up to dd7ee15fb8 2017-12-05 14:21:11 +01:00
Christophe Simonis dd7ee15fb8 [MERGE] forward port branch 9.0 up to ce038f5d15 2017-12-05 13:52:02 +01:00
Lucas Perais (lpe) 2a86e9245c [FIX][BACKPORT] Always round monetary values in database
backport of afef71d6b9

Original commit message:

Let `create` and `write` round monetary field values before sending them to the
database. Pass the values to be written to `field.convert_to_column`, so that
the currency can be retrieved from the values, and the value be rounded.
2017-12-05 13:46:06 +01:00
Xavier Morel 150fc064fd [FIX] product: image changes not sticking everywhere
Fixes #20046

Simply reverting e5ef1c5917 looks to
work *but* since I didn't note the repro case for the issue and don't
remember what it was it may re-introduce previous breakage. Instead,
ensure all "sizes" for the image are reset if any of the sizes is
present *and* Falsy by adding a final case to the conditional.

If any of the image fields is present and non-falsy one of the
previous branches will be taken, so we can just check that any of the
image fields is present at all (this implies it's falsy).
2017-12-05 13:35:51 +01:00
Romain Derie ce038f5d15 [FIX] auth_oauth: correctly retrieve user facebook email
Before this commit, you could never get the user's facebook email. Since there
was no email field on facebook response, email would be then set to an auto
generated value like 'provider_2_user_0123456789123456' by odoo.

Now, we correctly request user's email to facebook.

opw-782771
2017-12-05 13:29:06 +01:00
Adrien Dieudonne 6d7d6d9460 [FIX] web: debug_manager: change view_type to form in url
Before this commit, there were an error when you tried
to change the view_type directly from the url in debug mode.
The controller of the view wasn't defined and a crash happened
when we tried to render the DebugManager.View.

To fix this, we now wait for the 'switch_mode' which sets
the controller to the active view.
'do_load_state' is now chained to 'switch_mode'
2017-12-05 11:37:48 +01:00
Nicolas Lempereur 04bfd54013 [FIX] sales_team: multicompany issue typo 3ad1867e
3ad1867e could lead to wrong results in a multicompany setting because
the change got the company from the lead but it was intended to be
gotten from the user.

Since ('company_id', 'child_of', False) returned "root" companies, the
code still got a sales team but possibly one from another company if the
user was on another company that its sales team.

This would lead to an access issue that this commit solves.

opw-784455
closes #21428
2017-12-05 11:07:51 +01:00
Ruter fe8668e509 [FIX] web: Setting disable_favorites on Search View causes Exception 2017-12-05 09:31:00 +00:00
Ruter ed326e0569 [CLA] signature for ruter 2017-12-05 09:31:00 +00:00
jem-odoo 969184e4da [FIX] sale_timesheet: timesheet revenue should be zero on milestone 2017-12-05 09:59:37 +01:00
jem-odoo 1f09312bde [FIX] sale_timesheet: reset delivered qty when removing last timesheet line
When removing a timesheet line (on delivered quantity SO line), the delivered
quantity should decrease. This is the case when the is at least one timesheet
left, but not when we remove the last timesheet.
Forcing resetting value to zero make vendor bills flow, so adding
'sale_analytic_norecompute' key was required to force delivered
quantity.

This commit fix this bug, and provides some tests.
2017-12-05 09:59:37 +01:00
Alexandre Kühn 6cc5a9963b [FIX] web,*: time format from user's language
Before this fix, the chatter always showed dates of messages in military time format.

This was not the expected behavior, as the user could have had customize
the date and time format in the settings of the current language.

Steps to reproduce the issue:

1. Set Odoo in English
2. Settings > Translations > Languages > English
   2.1. Set Date Format to %m/%d/%Y
   2.2. Set Time Format to %I:%M:%S %p
3. CRM > (Select any opportunity with at least one message) > Mouse hover on elapsed time (e.g. "an hour ago")

Expected:

- It shows the customized time format (e.g. 11/07/2017 5:33:36 PM)

Results:

- It shows the military time format (e.g. Tue Nov 07 2017 17:33:36 GMT+0100)

opw-781647
2017-12-05 09:13:31 +01:00
Lucas Perais (lpe) 519555054a [FIX] web: BinaryFile not download when new record
Let's have:

- on res.company a binary file field named x_file
- on res.users a related binary field to company_id.x_file, and make it readonly
- On the res.users form view, display the new field
Before this commit in create mode, upon clicking on download the file, the server crashed, because the record id was empty.
Then, the JS crashed in turn because of the unhandled 404 from the server.

Since the id of a new record will always be unset, we choose to disable the download option in this very specific case

OPW 777042
2017-12-05 08:19:08 +01:00
Joren Van Onder b2f0af4543 [FIX] point_of_sale: allow searching a partner on >2 fields
When searching for a partner the ' ' (SPC) character can be used as a
field separator. You can search for e.g.:

'agr namur'

which will return the 'Agrolait, 69 rue de Namur,...' partner.

For some reason only the first space was considered a separator. So
e.g.:

'agr namur belgium'

wouldn't work.

This commit makes it so that every space character is considered a
separator.

Fixes #21357
2017-12-04 14:18:36 -08:00
Christophe Simonis a8d01cbf4e [MERGE] forward port branch saas-15 up to a447da75fd 2017-12-04 20:12:19 +01:00
Christophe Simonis a447da75fd [MERGE] forward port branch saas-14 up to e7d174a142 2017-12-04 19:25:51 +01:00
Christophe Simonis e7d174a142 [MERGE] forward port branch 10.0 up to 78aef7605c 2017-12-04 19:06:41 +01:00
Adrian Torres 78aef7605c [FIX] *: ordered group_by for field with capital letters
When doing a group_by in a tree view, and then ordering by an
aggregated field which contains at least one capital letter in its name,
you will get an error and won't be able to ordery by this field.

Why? read_group is called when sorting a group by, which calls
_read_group_raw which then goes to call _read_group_prepare, which will
return order by terms in this manner ['id asc', 'x_Test desc']
the problem with this is that postgres automatically converts
non-quoted/non-qualified column name to lowercase, of course this means
that if we have a field "x_Test" but no field "x_test", it will try to
look up "x_test" instead of "x_Test" and since the column doesn't exist,
it will throw a ProgrammingError.

This commit changes this behavior by wrapping the order_by terms generated in
_read_group_prepare with double quotes, which postgres interprets
correctly.

Fixes #21348

Cherry-Pick of c338e24ee7 as previous
forward-port has been badly done...
2017-12-04 18:49:31 +01:00
Christophe Simonis 8a9973bd2a [MERGE] forward port branch 9.0 up to c338e24ee7 2017-12-04 18:34:01 +01:00
Josse Colpaert 220bdb3587 [FIX] mrp: qty producing on update qty of mo
When updating the quantity of an MO, the qty we are producing on a work
order should possibly be updated.  When the finished product is tracked
by serial number it should be 1.0 when some quantity is still to be
treated.  (and not 0 as before)

opw-785190
2017-12-04 17:18:16 +01:00
Cedric Snauwaert 3549688b21 [FIX] account: fix reconciliation that create double entries in some case
commit 2f3b469dee fixes a problem
where open balance had to be added in the lines to create,
however in the case where no line is selected, a new one is created automatically
(for usability purpose) and the balance was not update correctly,
resulting in the creation of a double entry.
2017-12-04 16:33:53 +01:00