Commit Graph
117235 Commits
Author SHA1 Message Date
Gert Pellin c19f0a7a5d [FIX] point_of_sale: new table duplicates
Add new tables in POS screen, close the screen and resume the session
again, the tables you created duplicate

closes odoo/odoo#27924
2018-10-18 07:54:11 +00:00
William Henrotin 84481726dc [FIX] stock: add note field
Commit 37d20240a9 reintroduce lost note
field but not in a clean way.
This commit put the field in a proper tab.

Task : 1896143

closes odoo/odoo#28026
2018-10-25 07:54:42 +00:00
Odoo Translation Bot c2c88f359d [I18N] Update translation terms from Transifex 2018-10-25 10:21:44 +02:00
Yenthe V.G 992c4dbe38 [FIX] mail: set default _rec_name to avoid showing model with id
closes odoo/odoo#27186
2018-10-24 14:21:04 +00:00
David Arnold cbc72dba18 [FIX] purchase_requisition: traceback on validate
The subsequent code strongly suggests that pick_in can be None,
however, the raise_if_not_found has not been set properly.

closes odoo/odoo#27397
2018-10-20 21:22:37 +00:00
Christophe Simonis 58af18eb2f [FIX] account,sale_timesheet: don't enforce test journal currency
It was causing some tests failure due to 22f0da809e
2018-10-24 17:45:34 +02:00
Christophe Simonis 58525e29d8 [MERGE] forward port branch saas-15 up to bff43f0aa1 2018-10-24 16:14:52 +02:00
Christophe Simonis bff43f0aa1 [MERGE] forward port branch saas-14 up to 29e36457b2 2018-10-24 14:19:44 +02:00
Christophe Simonis 29e36457b2 [FIX] account: don't enforce test journal currency
It was causing some tests failure due to 22f0da809e
2018-10-24 11:57:42 +02:00
Yenthe V.G 7c45f22cea [FIX] mrp: remove useless upgrade boolean
The option enables a group, it does not install an enterprise module
Introduced at 85ed6a31a2

Fixes odoo/odoo#28080
Closes odoo/odoo#28081
2018-10-24 09:56:56 +00:00
Christophe Simonis 416ed10b7b [MERGE] forward port branch saas-14 up to ce2eb8464b 2018-10-23 18:04:26 +02:00
Christophe Simonis ce2eb8464b [MERGE] forward port branch 10.0 up to d5cc05c994 2018-10-23 18:02:45 +02:00
Martin Trigaux d5cc05c994 [FIX] doc: correct reference to the line in the file
Introduced at 94e82753ac
2018-10-23 16:17:58 +02:00
Martin Trigaux a0050c323c [FIX] doc: backport of ac37ca39ea to 10.0
To be compatible with sphinx >= 1.8
2018-10-23 16:17:58 +02:00
Martin Trigaux 27cc2ae3a9 [FIX] doc: backport of 9a07a4599c to 10.0
To be compatible with sphinx >= 1.6
2018-10-23 16:17:58 +02:00
Lucas Perais (lpe) fee419c7ea [FIX] project: template render attachments sudo
Related issue odoo/odoo#27256
use case is in there

Retrieving the access token for an attachment should be done as sudo
Also, we adapt the code to the method, which appears to be "api.one" (lol)

OPW 1888873

closes odoo/odoo#28074
2018-10-23 14:16:48 +00:00
mhamra 55899f849a [FIX] models: use expected parameter type
set_failed function expects an iterable object
Introduced at 32a58c0db3

Fixes odoo/odoo#27744

closes odoo/odoo#27911
2018-10-23 14:21:55 +00:00
Lucas Perais (lpe) eeae211176 [FIX] calendar: recurring event around DST
Be in timezone Europe/Brussels, where, in 2018, the DST switch
happens on 2018-10-28.

Create a recurring event starting on 2018-10-27 until 2018-10-29
at say, 8am

For the days before the 28, the time of the event will be correct

Before this commit though, for the days after the 28,
the meeting time will be shifted by one hour
This is because the rrule took a TZ aware datetime, and generated recurring
event dates with that same TZ, i.e. the one in STD time

After, this commit, all the meetings are well scheduled at 8am,

OPW 1895315

closes odoo/odoo#27985
2018-10-23 14:00:18 +00:00
Romain Derie ef48b81ab1 [FIX] website_sale: prevent other sessions to crash after checkout
Before this commit:
If an user has multiple session on a database (eg: he is connected both on his
smartphone and his laptop on the ecommerce), and there is a cart in these
session, confirming the cart on one of the session will make other sessions
unable to use the checkout anymore.

This is because other sessions will still contains the Sale Order that is now
'sent' and updating the cart will raise an error:
`It is forbidden to modify a sales order which is not in draft status.`

Now:
If the SO to be updated is not in `draft` anymore, we create a new one.

Step to reproduce:
  - Login on ecommerce from device A
  - Add product in cart, the SO will be added on session
  - Login on ecommerce from device B
  - Pay the cart (it will retrieve the SO from device A)
  - At that point, the cart is paid and the SO is removed from session on
    device B but other devices won't be able to use the checkout anymore
    as they still have the SO in session which is in `sent` state.
    Thus, any action on cart will raise the error

Note:
1. We can't implement that behavior in `sale_get_order()` as it is supposed to
   return SO in `sent` state after checkout.
2. We can't implement that behavior in `_cart_update()` as it is inherited in
   some module. Thus, implementing that behavior in `cart_update()` would change
   `self = order` but inherited methods would still have initial `self`.
3. Implementing the behavior in the controller it is already done (differently)
   in `cart_update_json()`.

Fixes #27508, closes #27794
2018-10-23 15:58:48 +02:00
Martin Trigaux 1ee180ee0d [FIX] doc: do not duplicate header
And use tabs instead of spaces
Otherwise it looks for the file named "__manifest__.py 2014-..."
2018-10-23 15:47:12 +02:00
Julien (juc) Castiaux 3008f7d254 [FIX] point_of_sale: Button spamming create duplicates
Spamming the save button when creating a new custommer in point-
of-sale create duplicate users. This PR disable the button once
clicked and re-enable it when all the processing is done.

opw-1895302

close #23919
2018-10-23 12:56:44 +02:00
Xavier Morel 35bb8304ab [FIX] doc: building on Python 3.6.7, 3.7.1, possibly 2.7.???
https://bugs.python.org/issue33899

tokenize.generate_tokens was altered to match the C tokenizer,
previously it would end the tokenization with just an ENDMARKER, in the
titled releases it adds a NEWLINE before the ENDMARKER if none is
present, this broke the parsing of jsdoc type specifications as Python's
tokenizer is used under the cover.

closes odoo/odoo#28056
2018-10-23 10:39:22 +00:00
Lucas Perais (lpe) eef4c3b48b [FIX] calendar: all day event shouldn't store in UTC
With a user in a distant timezone, like UTC +/- 11

Create a all day event.

Before this commit, the event was displayed across the wrong days
This was because the dates were converted from the user's timezone
into UTC before being stored.

Which is:
- start date at december, 12
- if the user's tz is utc-11: the date becomes december, 11 (at 1:00pm)
- at rendering, it becomes december, 11 (at 7:00am)

After this commit, we store the datetime field "as if" it were a date field
that is, we don't convert it to any particular tz

It is worth noting that, if one removes the allday mapping in the xml view,
an event that has been created as allday will get its start and stop date converted
to the browser's timezone, and will NOT be displayed as from 8am to 8pm as one could expect
This is considered as a limitation of the code, that was present before this commit anyway.

In any case, please do not revert this commit :D

OPW 1891110

closes odoo/odoo#27949
2018-10-23 11:26:28 +00:00
len-odoo 5dea3651f1 [FIX] website_sale: set user_id of newly created partners to the website salesperson
When an unlogger user places an order, a new partner is created on the fly when
the unlogged user is asked to place his delivery address.
The values he enters on the form are processed before being used.
In particular the team_id is taken from the order (typically website_sale team).
We add to the new values the salesperson id.
This value is then used in onchange_partner_id to update the order's user_id.

opw 1889510

closes odoo/odoo#28030
2018-10-22 12:32:36 +00:00
Gustavo Valverde 3426ce03b4 [FIX] base: set correct time format for es_DO
In Dominican Republic, only english speakers and the military use 24h time
format. Businesses handle their information using 12h time format with a.m.
and p.m.

closes odoo/odoo#28042
2018-10-23 07:21:30 +00:00
Gustavo Valverde 3f9d504bb7 [FIX] base: change DOP currency symbol position
closes odoo/odoo#28040
2018-10-23 02:07:53 +00:00
Christophe Simonis e744241d83 [FIX] web: trim tooltip text before comparison
The error is triggered at least on Chrome 69 on macOS.
2018-10-22 16:53:21 +02:00
Odoo Translation Bot 98ee84e976 [I18N] Update translation terms from Transifex 2018-10-21 03:22:16 +02:00
Olivier Colson 22f0da809e [IMP] account: Trigger a validation error when trying to set the same currency on a journal as on its parent company.
Until v12, doing this is wrong. The currency_id field of account.journal should only be used if the journal is in a different currency. Otherwise, this field should stay empty.

//NOTE FOR FORWARD-PORT: this commit should not be ported to 12.0 and further.
2018-10-19 15:04:12 +02:00
qsm-odoo 3a2939d494 [FIX] web_editor: disable strange resize handles on Firefox
See comments in the code for details...

Closes https://github.com/odoo/odoo/pull/27964
2018-10-19 14:48:51 +02:00
mhamra f891f51225 [CLA] signature for mhamra
closes odoo/odoo#27943
2018-10-19 12:40:26 +00:00
Robot Odoo ad872a9c1a [MERGE] website, *: fix some snippet options
* web_editor

See sub-commits for details.

closes odoo/odoo#27966
2018-10-19 14:58:45 +02:00
qsm-odoo 4150dd5849 [FIX] web_editor: fix background reset system for carousel items
When the user previews a background color, the background image of the
snippet is removed and re-added if the user chooses not to pick the
color. The background-image was not correctly added for carousel items.
2018-10-19 09:07:33 +00:00
qsm-odoo c2b8d2a301 [FIX] web_editor: review _setActive system for select-class
- Handle the case where one select-class is a subset of another
  select-class of the same group e.g.

  <... data-select-class="hello"/>
  <... data-select-class="hello world"/>

- Handle empty values <... data-select-class=""/>

Note: both cases worked but were not displaying the active checkbox
correctly in the editor UI.
2018-10-19 09:06:16 +00:00
qsm-odoo dea1372215 [FIX] website: restore options active system for carousel 2018-10-19 09:05:58 +00:00
Aaron Bohy 22a13073f0 [FIX] web: kanban quick create properly disabled
when grouped on field types for which it isn't supported.

Rev. 42e1efd disabled the quick create feature when the view is
grouped by date(time) fields. However, it hasn't been correctly
forwardported to 11.0 (with the new views). Indeed, the check was
done only once, at the initilization of the view. So if the user
selected another field to group by afterwards, the quick create
feature wasn't enabled/disabled accordingly.

Moreover, we didn't check if it was available when the user clicked
on CREATE in the control panel. So even if it wasn't (and thus if
there were no '+' icon in the columns), when the user clicked on
CREATE, the quick create widget was inserted in the first column.

This rev. fixes both issues.

Task 1878254

closes odoo/odoo#27867
2018-10-19 06:56:40 +00:00
Arnold Moyaux 433666b2d9 [FIX] stock: free reservation over reserve
Usecase to reproduce:
- 6 units in stock
- reserve 3 units on a move
- reserve 3 units on another move
- validate a third move with 1 unit

It raise the error could not reserve more than you have in stock.
It happens because when free reservation stole reservation from
an exisiting move with too much quantity available, it continues the
loop instead of stopping.

This commit stop the loop once we have enough quantity taken.

opw-1895578

closes odoo/odoo#27935
2018-10-18 13:49:57 +00:00
Christophe Simonis 54db75396f [MERGE] forward port branch saas-14 up to ef670016e6 2018-10-18 15:30:59 +02:00
Christophe Simonis ef670016e6 [MERGE] forward port branch 10.0 up to b8b33c6363 2018-10-18 14:52:51 +02:00
David Arnold b8b33c6363 [FIX] add res_company.sequence to base.sql
Seems like something similar to odoo/odoo#17111 can happen on Python 2.
The same change as #17111 is a bit involved for -stable, but this looks
pretty harmless.

Probably fixes #23781.
2018-10-18 14:24:37 +02:00
len-odoo e648f5fbe4 [FIX] sale: convert invoice values to the sale order currency
If the invoice is not in the same currency as the sale order, then there was an
inconsistency in the sales report, as it was considered to be the unit currency.
We keep the initial computation in case where the invoice currency is the same.

opw 1890381

closes odoo/odoo#27797
2018-10-18 08:31:19 +00:00
Denis Ledoux b7937ab6b7 [FIX] web: re-introduce on_change="0" to prevent onchanges for customization
In 10.0, adding on_change="0" allowed to prevent
default onchanges to occur for the field on which was added this attribute.

In 11.0, the rev. eaa66d1156
added a regression by removing this possibility.
It was an oversight, it was not an expected change
in the web client.

In 10.0, it's this line which bring this possibility:
https://github.com/odoo/odoo/commit/e8a00bc50da435d3859118ca127d20a2eb9a0cab#diff-ff0e90fb0eb4418a7f66e618e4b51323R444

opw-1883366

closes odoo/odoo#27952
2018-10-18 15:37:42 +00:00
Christophe Simonis 2c0a76fc7a [FIX] web: correct attribute name
Oversight of previous forward-port.
2018-10-18 17:32:11 +02:00
Christophe Simonis 9c3ec026c5 [MERGE] forward port branch saas-15 up to 54db75396f 2018-10-18 17:16:03 +02:00
Wolfgang Taferner 66f8ffe729 [FIX] stock: do not crash move_lines return a tuple with empty list
Typically if you use an onchange method to retrieve values on the server
and convert them to write it will also try to write empty values like
[(6, 0, [])] and this will crash as it has also the length of 3 but no
dictionary but a list

closes odoo/odoo#27937
2018-10-18 12:05:35 +00:00
Julien (juc) Castiaux 4c65499cca [FIX] mail: Emails are sent in reverse order
The CRON job that sends email sends them in a LIFO order instead
of a FIFO order which can lead to confusion when the order is
important.

Exemple, when updating multiple time an appointement, the last
update should be the newest mail clients receive in their mail box
which was not the case before this PR.

opw-1888601

closes odoo/odoo#27888
2018-10-18 09:24:00 +00:00
Martin Trigaux 4945495401 [FIX] base: display correct ondelete value
The on_delete value on an ir.model.field did not reflect the value set on the
field loaded in the registry

Fixes odoo/odoo#24464

closes odoo/odoo#27906
2018-10-18 08:48:37 +00:00
Luis González 4e239bcb1a [FIX] base: Typo in string of default code for server actions
"may be be void" -> "may be void"

closes odoo/odoo#27919
2018-10-18 03:03:23 +00:00
Goffin Simon 492f197c91 [FIX] account: Payments on invoices not in date order
Steps to reproduce the bug:

- Create a customer invoice I with an amount of 100$ and validate it
- Register three payments P1 at 11/10, P2 at 12/10 and P3 at 13/10
- Click on button "Print" and the report displays the payments in the right order
P3, P2, P1
- Click on button "Send by email" and click on the attachment with the report

Bug:

The report didn't display the payments in the same order, it displayed P1, P2, P3

opw:1888251

closes odoo/odoo#27895
2018-10-17 13:09:52 +00:00
Lucas Perais (lpe) ed5417b71f [FIX] project: wrong context key in task action
In JS, the groupBy attribute is a list of strings

The default_group_by key that is sometimes present in the XML views
gets converted to a list at somepoint.

Before this commit, the task action couldn't be used in the app Dashboard

After this commit, it can

OPW 1894751

closes odoo/odoo#27908
2018-10-17 15:35:04 +00:00