Commit Graph
129561 Commits
Author SHA1 Message Date
Thibault Delavallée 608ea7f85d [FIX] website_slides: lessen concurrent update by waiting slide completion
PURPOSE

Test frontend and UI tools of eLearning.

SPECIFICATIONS

When switching through slides using the fullscreen player it is quite
common to have concurrent updates on slide.slide.partner model as it is
used to store the viewed and completed. By correctly waiting for the
completion to be done we lessen potential concurrent errors.

LINKS

Task ID 1937768
2019-08-28 13:27:58 +00:00
Thibault Delavallée 9b12a8b9d7 [FIX] website_sale: fix access right issue when paying
PURPOSE

Test frontend and UI tools of eLearning.

SPECIFICATIONS

Commit fe518f1fea introduced a search on sale order model in checkout
process. However this may fail as access rights are not always granted

  * portal users can see orders linked to their company;
  * salesman and a lot of specific groups (accounting, ...) can see their own
    orders, all orders, or depending on some condition;
  * BUT standard users (employee only for example) cannot see any sale order.

Indeed they do not even have right to read, meaning a search fail. Let us
sudo the search as this is contained in a sub method used to fetch some
data.

LINKS

Task ID 1937768
2019-08-28 13:27:58 +00:00
Thibault Delavallée f93064606f [FIX] website_slides{_*}: fix completion computation, notably with certifications
PURPOSE

Test frontend and UI tools of eLearning.

SPECIFICATIONS

Since 9920f20e4c course completion when finishing a certification survey
is broken. Indeed channel completion is not correctly recomputed. A
certification course can therefore never be completed and awarded. This
commit fixes that and correctly update channel completion based on survey.

In this commit we also rename some methods

  * _compute_completion: renamed to _recompute_completion to avoid naming issue
    with computed field convention;
  * _post_completion_hook is not unnecessary as code in hr_skill can be done
    after calling super of _recompute_completion;
  * _completed_callback is renamed to _set_completed_callback to be coherent
    with slides naming;

LINKS

Task ID 1937768
2019-08-28 13:27:58 +00:00
jbm-odoo 58cf9b6754 [FIX] base: Open One2many with not yet updated values
When we have an onchange that modify items in One2many's lines (for
example the quantity of each line based on general quantity) and
we click on a record immediately after changing the field that
trigger the onchange, we have the the old value in the dialog box.
Indeed the dialog opens before the onchange has return the new
values, so the old one are used. This case appears only if the
One2many's line was never saved.

With this fix, we wait that the model is free of mutex, and so the
onchange is terminated before displaying it.

closes odoo/odoo#35306

Signed-off-by: Simon Lejeune (sle) <sle@openerp.com>
2019-08-28 13:51:40 +00:00
jbm-odoo cf7c9bd9b7 [FIX] mrp: Avoid creating new line when changing qty to produce
When we change quantity to produce in mrp, all component lines are
removed and new line with the updated amount to product are created.
The problem appears when we change the quantity to produce and directly
click on a component line, because we open the line that will be
deleted. So if we change the quantity for this component manually,
this suppressed line will be added with the new value. And the computed
line will be also be added. So the line for one component will be
present twice (one with computed value and one with manual entry value).

To avoid this problem, when we change the quantity to produce, we update
information of each line (instead of deleting and creating new one).
So if we click on a component line just after changing the quantity,
we open the updated line (and not de deleted one).
2019-08-28 13:51:40 +00:00
RomainLibert d6c65aa4d4 [FIX] base: allow users to read themselves in multicompany
You should always be able to read your own user whatever the company you
are logged into

closes odoo/odoo#36190

Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2019-08-28 13:47:39 +00:00
Jeremy Kersten c712e49b74 [FIX] website_blog: remove ranking computed field
No more used

closes odoo/odoo#36188

Signed-off-by: Jérémy Kersten (jke) <jke@openerp.com>
2019-08-28 12:56:25 +00:00
Yenthe666 89a59558aa [FIX] hr: fix typo in OdooBot notification
closes odoo/odoo#35971

Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
2019-08-28 13:06:07 +00:00
Martin Trigaux 8430da8f3f [I18N] base: export saas-12.5 source terms
closes odoo/odoo#36145

Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
2019-08-28 10:19:31 +00:00
Martin Trigaux f49e8879b5 [IMP] *: unify module manifests
The description should be an action for the user (i.e. "with this
module, you can ...")

Correct English errors
2019-08-28 09:55:34 +00:00
Martin Trigaux 95620bb03c [IMP] base: rephrase sentence
Was not clear groupby is the attribute
2019-08-28 09:55:34 +00:00
Martin Trigaux b4faa5d70c [FIX] base,web_editor: fix typo
Remove redundant _description
2019-08-28 09:55:34 +00:00
Martin Trigaux e212099d39 [FIX] mass_mailing: use better wording 2019-08-28 09:55:34 +00:00
RomainLibert 6aaef4a3d9 [FIX] website: fix ctx argument
In the call to Chart.js we pass a ctx which should be a DOM element,
however we pass `null` as the ctx.

It seems that what happens is that we look for the DOM element inside
the `document` (via getElementById) but this element is not yet inserted
into the document, hence this returns `null`.

Since we already have a reference to the canvas element which should be
used as ctx, we can probably just reuse this reference

closes odoo/odoo#36072

Signed-off-by: Adrien Dieudonné (adr) <adr@odoo.com>
2019-08-28 11:13:18 +00:00
Jinal Patel 85b5c9bbb4 [ADD] mrp: add BOM Type field on BOM tree view
task-1949618

closes odoo/odoo#32785

Signed-off-by: Simon Lejeune (sle) <sle@openerp.com>
2019-08-28 12:17:39 +00:00
Jinal Patel 59463c6a35 [IMP] mrp: 'Quality' option always visible in settings
task-1949618
2019-08-28 12:17:39 +00:00
Jinal Patel 3b520ed4f1 [IMP] mrp: rename filters
-'Waiting for Material' > 'Waiting for Component'
-'Material Available' > 'Component Available'

task-1949618
2019-08-28 12:17:39 +00:00
Jinal Patel 81577bf24e [IMP] mrp: remove unnecessary menus from MRP Configuration
-'Working Times'
-'Productivity Losses'

task-1949618
2019-08-28 12:17:39 +00:00
Jinal Patel 4781f1028a [IMP] mrp: stay UPDATE button in edit or read mode on MO
task-1949618
2019-08-28 12:17:39 +00:00
Jinal Patel dbc393ef10 [IMP] mrp: change position of CANCEL button on MO
task-1949618
2019-08-28 09:22:17 +00:00
Jinal Patel b3651ab9f9 [IMP] mrp: hide 'Material Availability' field in form view
-apply group_stock_multi_locations group on Miscellaneous tab

task-1949618
2019-08-28 09:22:17 +00:00
Jinal Patel 9f7e597126 [IMP] mrp: hide UNLOCK button in draft state
task-1949618
2019-08-28 09:22:17 +00:00
Jinal Patel e4bd824592 [IMP] mrp: hide attachment icon in edit mode
-also improve tooltip on attachment icon
-and also hide attachment count in edit mode

task-1949618
2019-08-28 09:22:17 +00:00
Jinal Patel cedb6d9440 [IMP] mrp: improve help message on MO
task-1949618
2019-08-28 09:22:17 +00:00
Aaron Bohy 711a10162a [FIX] web: enter edition editable list with <widget>
Let's assume an editable list view with a <widget> node in its
arch. Before this rev., when clicking on a field cell positionned
*after* the widget, the field next to the clicked one was focused.

closes odoo/odoo#36176

Signed-off-by: Géry Debongnie (ged) <ged@openerp.com>
2019-08-28 11:24:48 +00:00
Rémi Rahir 52c6a060d6 [FIX] base_setup: allow extension of the edition widget
The refactoring of the settings in a0c34138f88c4eb5d8a86340df55bbc091c5a252
did not properly take the enterprise edition into account. In
particular, we had lost the information about the expiration date.

This commit adds that information in community as the alternative would
be to extend the widget ResConfigEdition in web_enterprise which would
imply an explicit dependency between web_enterprise and base_setup and
we would like to avoid that situation.

closes odoo/odoo#36114

Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2019-08-28 10:35:09 +00:00
Odoo's Mergebot 7d6a326501 [MERGE][FIX] gamification, test_lint, web: Edge does not support obj spread operator
As of August 20 2019, Microsoft Edge partially supports ECMA2018.
For instance, `Promise.prototype.finally()` can be used, but the
spread operator does not work on objects.

Task-ID 2056070

closes odoo/odoo#36054

Signed-off-by: Pierre Paridans <pparidans@users.noreply.github.com>
2019-08-28 14:08:02 +02:00
Alexandre Kühn 6f6445be8c [FIX] gamification, web: Edge does not support obj spread operator
As of August 20 2019, Microsoft Edge partially supports ECMA2018.
For instance, `Promise.prototype.finally()` can be used, but the
spread operator does not work on objects.

Task-ID 2056070
2019-08-28 08:50:56 +00:00
Jigar Patel ed64250503 [FIX] mrp: update expected duration when finished planned date is change
task-1939533

closes odoo/odoo#35016

Signed-off-by: Simon Lejeune (sle) <sle@openerp.com>
2019-08-28 08:30:42 +00:00
Jigar Patel 90df41f0da [IMP] mrp: improve the usability of workorder Gantt view
- display WO in red which has a late planned start date.
- hide the WO which are in done or cancel state.
- show progress of WO.

task-1939533
2019-08-28 08:30:42 +00:00
Lucas Lefèvre a5d42ff6d9 [FIX] membership: Adapt customer and supplier filters
The fieds `customer` and `supplier` no longer exist
since 3e97cff.

But 9a0fedf re-introduced filters using those fields,
probably when rebasing the branch.

closes odoo/odoo#36165

Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2019-08-28 08:37:07 +00:00
qsm-odoo 4f27e52cab [IMP] web_editor, *: introduce and restore new web_editor UI
* mass_mailing, note, website, website_blog, website_form,
website_mass_mailing, website_sale

This commit, unfortunately, mixes three things:

- Restoring as much as possible the scss organisation to allow styling
the web_editor UI properly.

- Fixing some bugs like a border around the page once the editor is
loaded, no ability to scroll the snippets, etc

- Introducing a whole new UI for snippet options: a left panel instead
of the old dropdown & button overlay.

Note: this commit also do some linting and ES6 convertion even though
some of it has been done in the parent commit.

Note 2: some elements that were removed are still styled in the POS apps
but this is because part of a feature was removed while leaving dead
code behind, this is handled in another PR which is to be merged
(https://github.com/odoo/odoo/pull/36136).

Part of https://github.com/odoo/odoo/pull/36068
task-1942370

closes odoo/odoo#36068

Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
2019-08-28 09:04:55 +00:00
qsm-odoo 05f9b1f4e6 [REF] web_editor: do some linting and ES6 adaptation before UI refactor
This commit aims at linting and converting to ES6 some parts of
web_editor JS to avoid as much noise as possible in UI refactor in next
commit.

Part of https://github.com/odoo/odoo/pull/36068
task-1942370
2019-08-28 09:04:49 +00:00
qsm-odoo b47f097feb [FIX] web_editor, *: review assets organisation
* mass_mailing, point_of_sale, website

- Lib files were included twice
- Variables files were split but added multiple times in the same assets
  bundle
- Useless assets templates were defined or split
- ...

Part of https://github.com/odoo/odoo/pull/36068
Related to task-1942370
2019-08-28 09:04:25 +00:00
qsm-odoo 7acb22a5e5 [FIX] web_editor: restore moving snippets to nearest dropzone
Hard to say when this was broken since the current work and revert of
the editor: when dropping a snippet outside of a dropzone it was not
dropped in the nearest one anymore because the dropzones were somehow
destroyed first in the current code.

Part of https://github.com/odoo/odoo/pull/36068
Discovered while working on task-1942370
2019-08-28 09:04:18 +00:00
Priyanka Kakadiya 5f35819fff [IMP] web: remove 'ID' field from custom groupby dropdown
purpose of this commit is to remove ID from the fields to group by on the
searchview as it does not work nor does it make sense.

removed field 'ID' from custom group by on search view.

task-2028105

closes odoo/odoo#34752

Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
2019-08-28 08:43:03 +00:00
Aaron Bohy 9a4123995f [FIX] base_import: layout issues
This rev. makes the 'Formatting Options' area responsive.

Closes #34257

Task 2007558

closes odoo/odoo#36159

Signed-off-by: Géry Debongnie (ged) <ged@openerp.com>
2019-08-28 07:35:50 +00:00
Odoo's Mergebot 70a65b0132 [ADD] pos_adyen: generic payment interface and Adyen integration
This does two things:

- Makes it easy to implement new electronic payment methods in the POS by extracting a generic payment interface from the `pos_iot` enterprise module, and
- Uses this new interface to implement Adyen's Point of Sale Terminal API

For more info see individual commits.

Internal task: https://www.odoo.com/web#id=1981799&model=project.task&view_type=form&menu_id=

closes odoo/odoo#35702

Signed-off-by: pimodoo <pimodoo@users.noreply.github.com>
2019-08-28 10:57:36 +02:00
Mohammed Shekha 555a2fd93e [IMP] stock: add inline form view for move_ids_without_package o2m
Before this commit the default form view was opened for this o2m on mobile
but there was too much fields.

As we want to show the same fields as the editable list in desktop, we
added an inline form view that will be used on mobile.

Task ID : 2031163

closes odoo/odoo#34830

Signed-off-by: Adrien Dieudonné (adr) <adr@odoo.com>
2019-08-28 07:37:09 +00:00
Hardik Prajapati 272b041e53 [FIX] web: keep nocontent tooltip in center
Before this commit: nocontent tooltip was not diplayed in center

After this commit: nocontent tooltip will be displayed in center,
toggle o_list_view class which should not be added if nocontent
help is displayed, as there is no listview to display so remove
o_list_view class

task-2008371

closes odoo/odoo#34178

Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
2019-08-28 07:25:32 +00:00
Pierre Paridans d431f94c75 [FIX] test_lint: adjust ES version for supported browsers
The EcmaScript version was recently raised (see commit
odoo/odoo@7423e20) to ES9/ES2018.

Sadly this specification is not fully supported by all ever-green
browsers (Chrome, Firefox, Edge, Safari...).

This commit rollback to ES8/ES2017 because MS Edge doesn't support the
"Spread in destructuring" operator (e.g. used for the creation of a new
object).

In a nutshell this version is equivalent to es2016 + async/await.

References:
- https://github.com/tc39/proposal-object-rest-spread/blob/master/Spread.md
- https://kangax.github.io/compat-table/es2016plus/#test-object_rest/spread_properties
- https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/Spread_syntax
2019-08-27 21:43:42 +00:00
william-andre d201a39357 [IMP] account: rework the reconciliation widget
Task 36284
Change the visual aspect of the reconciliation widget:
* Use a tab system to change modes
* Matching for receivable/payable (and liability)
* Matching for types not above
* Create a new line
* Batch Payment
* Sale Order
* Add a keyboard navigation
* Improve the search bar and use a real search view to do so
* Remove the constraint that prevent to select a line already selected
on another statement. Instead remove it when a reconciliation is
validated
* The lines already proposed are proposed last on other statement
lines
* Put the lines with exact amount matching first in the propositions
* Improve when Rainbowman shows
* Change the order of the propositions: older show first
* Remove the title on top of the view (and the ability to edit it)
* Fix some breadcrumb issues
* Also add lines from receivable/payable without partners in the manual
reconciliation widget.
* Propose things to do if there are no lines found in the manual
reconconciliation

closes odoo/odoo#32631

Signed-off-by: Quentin De Paoli (qdp) <qdp@openerp.com>
2019-08-27 11:26:50 +00:00
Martin Trigaux ca9ea81932 [REV] base: revert 2486259ef9
The commit was for performance reasons but introduced regressions as
explained at
https://github.com/odoo/odoo/pull/29779#issuecomment-524346268

Reverting until finding a better patch

closes odoo/odoo#36143

Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
2019-08-27 14:55:37 +00:00
Xavier-Do 7c21999537 [FIX] core: Correctly handle log_level in odooTestResult
Before this commit --log-level had no impact on test logs.

We need to check logger "isEnabledFor" before makeRecord
since logger will make this check in error,warn,log...
dedicated function before making call to _log.

We also need to use modules.py runner instead of unittest
logger in OdooTestRunner (test will allways be a suite there)

closes odoo/odoo#36142

Signed-off-by: Romain Libert (rli) <rli@odoo.com>
2019-08-27 15:01:38 +00:00
Julien Castiaux 24c92d8b95 [FIX] account: move group visible search to inherited view
Make sure your user does not have the "Analytic Accounting" group,
access the Invoices Management Report, traceback.

The problem is linked to groups. When they are used on model field, the
field is removed by the ORM. When they are used in view field, the field
is set as invisible. As both fields were restricted to the group, the
frontend was trying to render an invisible field using a removed field
causing the traceback.

The problematic field has been moved to a dedicated inherited view with
the group applied on the entire view. This cause the field not to be
rendered when the user does not have the group.

closes odoo/odoo#36122

Signed-off-by: Xavier Morel (xmo) <xmo@odoo.com>
2019-08-27 11:11:10 +00:00
Raphael Collet c3ebc0b987 [FIX] fields: do not update translations for no record
When a translated field is set on new records, one should not update
translations in 'ir.translation'.

closes odoo/odoo#36138

Signed-off-by: Raphael Collet (rco) <rco@openerp.com>
2019-08-27 14:25:44 +00:00
Christophe Monniez a893a51771 [FIX] account: install all l10n modules in one pass
Before this commit, the test was installing l10n_ modules one by one in
a loop. Since the orm improvements, this fails because
button_immediate_function creates a new registry and the test setUpClass
still uses the old one, leading to a CacheMiss.

With this commit, the button_immediate_install method is used on the
modules recordset.

closes odoo/odoo#36105

Signed-off-by: Xavier Dollé (xdo) <xdo@odoo.com>
2019-08-27 08:16:06 +00:00
Mohammed Shekha 6952ee18bc [FIX] web: crashmanager wrong syntax of arrow function
arrow function used for error handler and error function is defined
inside inner function so this will get changed, need to use self,
also arrow function doesn't have its own arguments object,
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Functions/Arrow_functions

Issue raised from following commit:
https://github.com/odoo/odoo/commit/2d6dc75a2cb5fa81189920d0f7fdc7b7f12132ab

task-2052484

closes odoo/odoo#35788

Signed-off-by: pimodoo <pimodoo@users.noreply.github.com>
2019-08-27 12:13:43 +00:00
David Beguin e74c6ef86a [FIX] website : fix visitor cookie expiration
Before this commit, the visitor cookie was expiring by default on
browser session close on firefox. On Chrome, the cookie was always
valid after browser session closing.

On Firefox, the expiration date must be set to make the cookie still valid
after closing the browser.

The same thing happened with livechat_session cookies set
in context of livechat request.

The cookie expiration date (100 years to 'never' expire) have been added.

Linked to original Task ID : 2028059

Task ID : 2060381
PR #36126

Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2019-08-27 12:12:37 +00:00
Jeremy Kersten ed19f90992 [FIX] website: rte_translator try to try to fix
using the same trigger than l72 for the same action.

We just set the cat amount the pigeons, and hope to fix random red's runbot

closes odoo/odoo#36110

Signed-off-by: Christophe Monniez (moc) <moc@odoo.com>
2019-08-27 08:54:58 +00:00