Commit Graph
114132 Commits
Author SHA1 Message Date
Arnold Moyaux 81e983443c [FIX] stock: unlink move line don't update move state
Use case to reproduce:
- Go for a delivery order and use show detailed operations mode
- Have something reserved on a picking
- Manually delete the stock.move.line
-> The move state is not adapted to the new state of the stock move lines

It happens because the move state is not computed not
update on the move line unlink method.

This commit use the existing move function in order
to compute the state and add a test.

A part of test_stock_flow_74 is updated. Since procurement
refactoring make a move mto and confirm it will not work
since purchase or mrp are not install (Usererror). Also do an unreserve
on a draft move is not a real use case and should not pass
it in waiting since moves orig are never created.
2017-12-12 14:55:55 +01:00
Pierre Masereel 96c3001f0e [FIX] delivery: compute package weight
The package weight is computed by summing all move lines related to it,
which is wrong, because if you have a package that is in two pickings,
its weight will two times bigger than the real weight.

To fix this, we will compute the weight based on the quants in the
package, except if we are opening the package from a pickin, it's weight
will be the sum of move lines of the package that are in the current
picking. This allow user to see the weight of a package after a put in
pack when there are not yet any quants in the package
2017-12-12 13:34:06 +01:00
Pierre Masereel b62973e901 [REF] stock: packages and report
- delivery slip: remove mention of packages
- package: fix the report's traceback
- picking: moved the packages references to a table at the bottom of the report
2017-12-12 13:34:06 +01:00
Pierre Masereel 3799043fdb [FIX] stock: move entire package
When an entire package is moved from a location to another and reserved,
we can process all the move_lines of a package in one step.
2017-12-12 13:34:06 +01:00
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