Commit Graph
117975 Commits
Author SHA1 Message Date
Florent de Labarre 54942f0921 [FIX] product: prevent modifying variant attributes
On the product_normal_form_view
to be consistent with the product_variant_easy_edit_view view.
product.attribute.value values should not be modified from the product view but
using the variant configuration from the product

Consistent with what was wanted at a4d88c9efd

Closes #23298
2018-03-14 10:47:37 +01:00
Martin Geubelle 7afc5fd6ad [REF] *: put clickable in widget options for statusbar
The widget statusbar was using an attribute `clickable` on the field widget
to define if the statusbar was clickable.

This attribute is in fact not a field attribute but a widget option so it
has been moved accordingly.

Note that a retro-compatibility adapation is done in the field widget.
2018-03-14 09:38:23 +01:00
Géry Debongnie 64d47c0bc5 [IMP] update ace editor to v1.3.1
Note that we do not do a custom build anymore, since we lazyload the
files anyway.  A custom build will save a few kb, but will not do any
meaningful change to the user experience.  However, it dies impact
negatively our ease of maintenance, so standard build it is.
2018-03-14 09:02:16 +01:00
Aaron Bohy b574104ebc [FIX] web: don't push state of loaded client actions
Loaded actions (i.e. executed from url state, e.g. after an F5)
should not push their state back to the url. This was working fine
of act_window actions, but not for client actions, and this was
causing an issue in Studio as the same mechanism is used to prevent
the main Studio client action from pushing its state into the url
(to keep the state of the edited action in the url instead).
2018-03-14 08:31:39 +01:00
Jeremy Kersten e449055189 [FIX] website_sale: disable link from pivot view for sale.report
Before this commit, linking was enable for pivot view of model sale.report.
User that click on a cell will be redirected on a default view list/form
with all fields.

Now linking is disabled.

If you want to open the sale order on click, you need to start with the
pivot view from model sale.order.

This commit closes #23445
2018-03-13 18:16:12 +01:00
Goffin Simon e68ab50a77 [FIX] payment_authorize: test_10_Authorize_form_render
Introduced by 669c23d58d

opw:1817597
2018-03-13 17:48:16 +01:00
Thibault Delavallée dab7368c43 [IMP] doc: improve wording of guidelines introduction
Purpose of this commit is to clean a bit the wording and to clarify how to
handle guidelines between stable and development versions.
2018-03-13 17:26:29 +01:00
Thibault Delavallée 820926f5ba [IMP] doc: improve guidelines related to Git and commit messages
Purpose of this commit is to explain with more details how to write commit
messages. Content of the Git section is also updated with last decisions
and conventions.
2018-03-13 17:26:29 +01:00
Laurent Smet f1608829a1 [FIX] account: add missing constrains dependencies
Create a move line having:

amount_currency = 1000
debit = 0
credit = 1000

The error is raised, it's ok.

Now, create a move line having:

amount_currency = 1000
debit = 1000
credit = 0

Then save, edit and write:

debit = 0
credit = 1000

No error raised, it's wrong!

-opw 1818714
2018-03-13 16:55:36 +01:00
Jeremy Kersten 4252cd7053 [FIX] doc: update footer links
Synchronize footer from odoo.com with the documentation.
2018-03-13 15:51:15 +01:00
Nicolas Lempereur c2f910717a [FIX] portal: dynamic chatter not editable
60c920d4a should solve duplication of chatter when editing the website.

But portal module doesn't depends on website, so eg. on a instance with
just helpdesk (and no website) we would not see the chatter on the
frontend.

This fix reverts 60c920d4a and adds another solution not depending on
website.

opw-1813792
closes #23614
2018-03-13 15:41:59 +01:00
Goffin Simon 669c23d58d [FIX] payment, payment_authorize: company field in authorize.net
Steps to reproduce the bug:

-Just purchase a simple product using Authorize.net
-Click on "Pay Now" to be redirected to Authorize.net gateway

Bug: The company field added during checkout page was not filled.

opw:1817597
2018-03-13 15:02:51 +01:00
Bole f521606d12 [CLA] signature for dajmi5
Done at #23606
2018-03-13 14:45:27 +01:00
Lucas Perais (lpe) d4c8a7cfb4 [FIX] web: view dialog select among filtered entries
On an editable line with a many2one
Click to create a record
Click on create a record in the many2one
It opens the form view of the object in a modal, which has a many2many list, which choices are domainized
Click 'add an item' on this list
It should open a modal with the filtered choices
Click on any of the existing record

Before this commit:
There was a traceback in JS
That was because the event bubbled up to a parent, when it shouldn't

After this commit:
The whole flow unfolds without errors

OPW 1823205
2018-03-13 14:35:05 +01:00
mrshelly 255f9ee330 [FIX] hw_scanner: add missing import
`os.path.isdir` was not being imported
2018-03-13 14:29:25 +01:00
Priyanka KakadiyaandMohammed Shekha 97fe1f0507 [FIX] web: FormView: handle string attribute on groups
Before this rev., this attribute was ignored for groups containing
sub groups.

Task 1786309
Closes #23514

Co-authored-by: Mohammed Shekha <msh@openerp.com>
2018-03-13 12:51:44 +01:00
Aaron Bohy c761ab2c5b [FIX] mail: redirect: prevent double-clicks
This rev. increases the wait interval of the redirect handler
called when a document is clicked in a mail thread (e.g. in the
'Inbox' in Discuss). This increases the protection against
double-clicks (preventing the document from being opened twice,
thus making twice the required RPCs, and from appearing twice in
the breadcrumbs).

A more robust solution (at the ActionManager level) will be
developed for saas-11.2 (where the ActionManager has been
refactored and is testable).
2018-03-13 12:51:44 +01:00
Aaron Bohy 7263424622 [FIX] web: Kanban: less tweak to prevent overflow
When the bottom left and right areas were taking to much space, the
right one overflowed the kanban card, because those two areas
weren't allowed to shrink. This might occur for example on the
sale.order view.
2018-03-13 12:51:44 +01:00
Aaron Bohy afbf90db00 [FIX] im_livechat: avatar size in operator kanban view
This rev. improves the layout of the inner kanban view for
operators in livechat channels, mainly by setting a max-width on
their avatar (with classname 'o_kanban_image').

The motivation of this commit comes from a feedback following an
internal migration.
2018-03-13 12:51:44 +01:00
Aaron Bohy 61f64c0166 [FIX] web_editor: FieldHTML: break long words
to prevent them from overflowing the form sheet.
2018-03-13 12:51:44 +01:00
len-odoo 0c5841dccf [FIX] website_sale: display prices using public user pricelist on the shop
When a pricelist was set on the public user that was different from that of the
website, the prices were displayed using the public user default currency,
but the currency symbol displayed was the website default currency.
The issue was that in the template, the currency was accessed as a computed,
related field of website while the price was obtained using a function call.
In the first case the field was obtained using sudo, and thus the call would not
get the public user pricelist.

Equivalent to #23519 for odoo 11.0

opw-1819230
2018-03-13 12:46:37 +01:00
Nicolas Martinelli b522ab5772 [FIX] account: tax rounding
- Set 'Round Globally'
- Create an excluded tax of 10 %
- Create an invoice for a product costing 34.55, and apply the tax.

The tax on the invoice is 3.46, while the tax on the tax line is 3.45.

When rounded in `compute_all`, the tax amount is 3.455, which is the
value expected. However, the `create` method won't round this value
before storing, leading to the inconsistency.

We make sure to round the amount to the currency precision, so the
value 3.46 is recorded.

opw-1819902
2018-03-13 12:42:54 +01:00
Nicolas Lempereur 088e3d2fec [FIX] website_event_sale: pricelist show no discount
On the website when selling a ticket, a percentage discount may be
applied on the ticket price.

This percentage is calculated as:
  {event product price} - {event product price reduced} / {event product price}

So with a ticket price 20, a linked product priced 60 reduced to 30, we
would get a ticket price 10 on the website.

This commit hide the discounted price if the pricelist that is applied
was configured as "Discount included in the price".

opw-1807889
closes #23611
2018-03-13 12:24:58 +01:00
Christophe Simonis c921d94236 [MERGE] forward port branch saas-15 up to 3730a0d2df 2018-03-13 12:05:36 +01:00
dbh 062a8258a7 [FIX] mail: load more messages
The feature has been broken by rev. 02ec09cb1.
2018-03-13 11:55:04 +01:00
Darshan Kalola 2b392636c4 [FIX] web_editor: rpc of 'many2one' snippet option
Before this commit, changing the value of a many2one field on the
frontend was not possible anymore since 11.0 because the RPC 'order'
parameter was not properly formatted with the new conventions.

See task-1767802
Closes https://github.com/odoo/odoo/pull/23545
2018-03-13 11:37:59 +01:00
Duc Dao 66c7e130d5 [FIX] base_setup: don't crash if template is empty
Before this commit:

* Activate debug mode.
* Go to general settings > Document Template.
* Change the Template selection to the empty value.
* Click on "Edit Header".

Result: Traceback.

This happens because we try to concatenate the value of the template
field to a string, and since it's empty (False) boolean and str can't be
implicitly concatenated, this of course raises an uncaught error.

After this commit:

* We check if a template has been selected before performing the
concatenation.

Closes #22736
Fixes #22622
2018-03-13 10:53:32 +01:00
Adrian Torres 84b6c46943 [FIX] registry, loading: re-init inherited SQL views
Before this commit:

* Install any module that creates a SQL view and another that extends
this view.
    e.g.: sale and pos_sale for `report.all.channels.sales`.

* Uninstall the module that extended the SQL view.
    e.g.: uninstall pos_sale.

* Try to access the view from the web client -> Traceback, table not
found.

This happens because when reloading the registry, postgres drops the sql
view and it must be re-initialized.

After this commit:

We solve this issue by calculating all missing tables/views during the
uninstallation process, and re-initializing all of them right before
reloading the registry.

Also remove sql-view hacks in the modules `sale` and `sale_margin`.

Fixes #23528, #23529, #23530
2018-03-13 09:41:43 +01:00
Goffin Simon 31a0bdec73 [FIX]stock: Default scheduled date in a stock.picking
When creating a stock.picking with the barcode, a default scheduled date
is required if you want to go further.

opw:1824629
2018-03-13 09:24:53 +01:00
Martin Trigaux bfffe17d37 [FIX] account: duplicated entry in pot file
Added at 57ff6a17b7 and 3715244a51
2018-03-13 08:47:15 +01:00
Christophe Simonis 3730a0d2df [MERGE] forward port branch saas-14 up to 0e898eae35 2018-03-12 18:48:15 +01:00
Christophe Simonis 0e898eae35 [MERGE] forward port branch 10.0 up to 0440e25380 2018-03-12 18:16:02 +01:00
Nicolas Lempereur 1653f39d53 [FIX] website_sale: 40px for mobile/list view/desc
When activating the list view of product and description, if the
description was too big things were overflowing over their box and
became unreadable.

The issue is that the height limit on description was of 200px for
tablet device and there was no lower limit. Thus the limit of an product
line being 200px: the description + picture could break out of the box.

With this change, the description at lowest width devices is limited to
40px as is the case for the grid view (which is very similar on low size
devices).

opw-1819184
closes #23604
2018-03-12 17:31:31 +01:00
Grzegorz Krukar 3715244a51 [FIX] account: missing 'Enterprise' labels in Invoicing settings
This patch is a workaround waiting for the real patch in upgrade field widget.

Export source to match recent changes in account module

Closes #22984
Fixes #20030
2018-03-12 16:51:44 +01:00
Bole afa02f15ee [CLA] signature for dajmi5
Done at #23602
2018-03-12 16:11:05 +01:00
fgi-odoo 93062742ab [FIX] project: correct spelling mistake in tour
Closes #23598
2018-03-12 15:46:33 +01:00
Martin Trigaux 9e1bb18101 [FIX] base: typo 2018-03-12 15:46:33 +01:00
Martin Trigaux 1a4d736a86 [I18N] website_crm: fetch translations
To get the changes following 6f18af73e0
opw-1813360
2018-03-12 15:04:18 +01:00
Christophe Simonis 0440e25380 [MERGE] forward port branch 9.0 up to 7c6da3e076 2018-03-12 14:33:58 +01:00
Martin Trigaux b661881e35 [IMP] base: set a create_date on first records
create_date is not required but may be assumed as always set such as in
base.partner.merge comparison
The administrator had no create_date set

Avoid errors in merge wizard if one of the record has no create_date

Fixes #22730
2018-03-12 14:31:05 +01:00
Odoo Translation Bot 1027f5ace7 [I18N] Update translation terms from Transifex 2018-03-12 14:30:40 +01:00
Géry Debongnie e7fab23420 [FIX] web: better experience for one2many edition (paged)
A big problem with the o2m edition happens when the user has a full page
(so, in general, 40 records) and click on add.

If the o2m is in editable="bottom" mode (which is actually a really
common usecase), then the next record will be added at the end.
However, since we have a limit of 40, it will immediately go to the next
page.

The effect is even weirder when there is a required field in the tree
view.  In that case, the new record appears correctly, the user can edit
it, then, as soon as the required fields are set, it will immediately
disappear from the current screen.

In this commit, we have a really simple solution: we simply increase the
limit in this case.  An interesting thing is that it is actually temporary:
when the user goes to the next page, the limit is back to its original
value (due to the pager click: it resets the value to what the pager knows).
2018-03-12 13:53:39 +01:00
Raphael Collet 2ea3c333e4 [FIX] models: update non-stored inverse field on several records
Issue: when the inverse method writes on a dependency of the first record, it
invalidates the cache of the field for the other records...  Solution: simply
evaluate the inverse method one record at a time.
2018-03-12 13:35:57 +01:00
Goffin Simon 96ebf00ca8 [FIX] account: Due date should be readonly on open invoices
The due date is printed on the invoice given to the customer and then
it is quite "official". That's why it shouldn't be correct to change it
when it's validated.

opw:1823175
2018-03-12 13:35:06 +01:00
Raphael Collet c04685e54e [FIX] models: update non-stored inverse field on several records
Issue: when the inverse method writes on a dependency of the first record, it
invalidates the cache of the field for the other records...  Solution: simply
evaluate the inverse method one record at a time.
2018-03-12 13:30:43 +01:00
Nicolas Lempereur 60c920d4a1 [FIX] portal: no dynamic chatter on edit so no dup
When editing a view on the frontend with a dynamic chatter (chatter
added dynamically to the view), if that part was edited, that
dynamically rendered part would be saved as is. Thus we would get a
duplicated chatter (with the first one statically the rendering at the
edit time).

opw-1813792
closes #23593
2018-03-12 13:12:06 +01:00
Aaron Bohy a0b06afcf3 [FIX] web: 'toggle_button' widget in edit mode
The 'toggle_button' widget is one of special field widgets that
can trigger changes in readonly mode (in this case, toggle the
boolean value when clicked). It was working fine in form views in
'readonly' mode, as in this case, the new value is saved directly,
and the form view is re-rendered (a new widget is created with the
new value).

However, in 'edit' mode, the value isn't saved directly (the user
has to click on 'Save' to save the changes), the widget is reset
with its new value, and the reset wasn't correctly handled in this
particular widget.

Fixes #23400
2018-03-12 12:56:00 +01:00
Aaron Bohy 8a1603eeda [FIX] web: don't scroll to top when opening a dialog
Steps to reproduce the issue: on an MD sized screen (i.e. such that
the chatter is below form views), go to a sale order in edit mode,
scroll down and click on 'Add an item', a modal opens, and the form
view behind scrolls back to the top, whereas it should keep its
scroll position.

This is because the ActionManager listens to event 'DOM UPDATED',
and when it occurs, it restores the current action's scroll
position (the main purpose is to restore the scroll position of a
previously visited action to which we return using the breadcrumbs).
When a dialog opens, this event is also triggered, but in this case
we should not restore the scroll position of the action in the
background.

Fixes #23491
2018-03-12 12:55:40 +01:00
Romain Derie f02cd2977e [FIX] website: use user timezone when handling date in page property
Before this commit:
1. The date would be displayed as UTC regardless of the user timezone.
2. The date would be sent to the backend in the browser timezone

Now we correctly take the user timezone into consideration when handling date.

Step to reproduce:
  - Install a second language where time format is: %H.%M.%S or %H,%M,%S
    (eg: Finnish, Bulgarian, Albanian )
  - Set it as website default's language
  - Open page properties dialog on any page
  - The date looks correctly displayed but it is in fact the UTC hour and not
    the user timezone date. (eg: 2 hours missing in Albanian case, it would
    show '2018-Pri-05 02.11.02.' instead of '2018-Pri-05 04.11.02.')
  - If you save, it will crash since it will send the wrong date format to the
    backend that is expecting 'YYYY-MM-DD HH:MM:SS' format.

Closes #23500, closes #23566
2018-03-12 12:06:55 +01:00
Nicolas Martinelli 6f18af73e0 [FIX] website_crm: contactus_thanks
Commit 4ecbacaf59 changed the XMLID of the `contactus_thanks` page,
but didn't adapted the .pot file. Therefore, the translations were not
loaded anymore.

opw-1813360
2018-03-12 12:03:13 +01:00