Commit Graph
119535 Commits
Author SHA1 Message Date
Martin Geubelle 9a98a4d60e [IMP] base: search template view based on key in addition to xml_id
In Studio, users can create views, reports, etc. which do not have an
xml_id (no record in 'ir.model.data' from import/install).

After this modification, the template can use the t-call using a readable
key on newly created views.
2018-08-13 17:09:28 +02:00
Christophe Matthieu ede9960a78 [FIX] qweb: correctly compile falsy t-value
An empty t-value is a empty string, which cannot be compiled as an expression.
The value is now considered as None so it can be compiled.
2018-08-13 17:09:28 +02:00
Christophe Matthieu 79a0f401a4 [IMP] web: add options to dragAndDrop test util function
There is now an option `continueMove` that can be used to extend a previous drag
done in this function.

The option `position` has also been extended to take an object (to precise the
move position).
2018-08-13 17:09:28 +02:00
Christophe Matthieu 5779807a31 [IMP] base, hr_timesheet: add option digital in qweb field duration
The option `digital` has been added. It allows to display "01:00" instead of "1
hour". This behaviour was implemented in a report (timesheet) but the logic
was done in the XML, which is not adequate.

This commit also allows to have a negative value for this widget.
2018-08-13 17:09:28 +02:00
Martin Geubelle 9dbf815dd8 [REF] *: modify templates to allow smoother modifications
With the report editor in Studio, some reports were not easily editable (not
idiomatic XML, too much Python logic in XML, etc.).

These reports have been cleaned up.
2018-08-13 17:09:28 +02:00
Christophe Matthieu 4d3a776389 [IMP] web: avoid failed tests affecting the next ones
When using positional clicks (among other examples) in tests, a previous failed
test might affect a next one because the assert failures are displayed on the
top of tests.
2018-08-13 17:09:28 +02:00
Christophe Matthieu 8f216482b8 [IMP] web: propagate many2many attributes to the sub FieldMany2One
The FieldMany2ManyTags uses FieldMany2One in its implementation.
Before this commit, the field attributes were not propagated to the sub field.
In particular, the attribute `can_create` is useful to be propagated.
2018-08-13 17:09:28 +02:00
Christophe Matthieu 6ca026119e [IMP] web: add method to convert JS domain into python condition 2018-08-13 17:09:28 +02:00
Christophe Matthieu cad272d5b6 [IMP] base: log wkhtmltopdf error
If wkthmltopdf silently raises an error without any error code, there was
previously nothing displayed to help debugging.

The error is now logged as a warning.
2018-08-13 17:09:28 +02:00
Christophe Matthieu 65e7ce0bb2 [FIX] web: load only once the session.js 2018-08-13 17:09:28 +02:00
Martin Geubelle 7f4b4f86bd [IMP] web: add MutexedDropPrevious in concurrency
This new helper is meant to solve the following use case: serialize a number
of concurrent rpcs while skipping the rpcs that arrive in between the mutex.
2018-08-13 17:09:28 +02:00
Martin Geubelle 971629b9fe [IMP] web, web_tour: handle iframe in tests and tour
In both test util functions (`dragAndDrop`) and tours, using elements in iframe
was not supported.

As a jQuery selector won't work with an iframe, when using a selector like
`div.o_my_class iframe p:first` the tour manager will split the selector, which
will result to `$('div.o_my_class iframe').contents().find('p:first')`.
2018-08-13 17:09:28 +02:00
Christophe Matthieu bae6494520 [FIX] web: apply css border to the table 'th' like the 'td' 2018-08-13 17:09:28 +02:00
Vincent Schippefilt c38290a3c9 [IMP] web: add text decoration classes 2018-08-13 17:09:28 +02:00
Christophe Matthieu f69ebfcfe6 [FIX] qweb: correctly display qweb error message
When compiling the qweb template, if an error occurs, an error message is
displayed with the corresponding failed node.

This messsage was not always correct because the node is modified in place
during the compilation proccess.

The template is now re-read before displaying the error.
2018-08-13 17:09:28 +02:00
Christophe Matthieu 24657828b5 [FIX] qweb: converted profile feature to py3 2018-08-13 17:09:28 +02:00
Christophe Matthieu acbcf36db4 [IMP] qweb: add many2many qweb widget
Instead of looping on x2m values in the qweb report, this new widget will
automatically render the x2m values for you (separeted with a comma).
2018-08-13 17:09:28 +02:00
Christophe Matthieu 14176015f5 [IMP] qweb: add method who defines qweb widget options
Each qweb widget should now explicitily define a method
`get_available_options` which specifies all options used in the widget
rendering.

The options are a dictionary with the option as key and the option type as
value (e.g. string, integer, array, model, etc.).

This is used by the Studio report editor (to customize widget options) and parsed
in JS.
2018-08-13 17:09:28 +02:00
Christophe Matthieu 32b269d3d5 [IMP] web: add default option to DomainSelector
This option is used to set a default domain value when creating a new node
(instead of [['id', '=', 1]]).
2018-08-13 17:09:28 +02:00
Christophe Matthieu 061175e598 [IMP] web: add more filtering and sorting options on ModelFieldSelector
A new `filter` option has been added to filter fields with an optional function.
A new `order` option has been added to sort displayed fields.

The `followRelations` options have also been extended to take a function.
2018-08-13 17:09:28 +02:00
Christophe Matthieu e082ee38e8 [IMP] qweb: adding t-options-key="value"
This change greatly facilitates inheritance and xpath and avoids having
to rewrite each time the entire dictionary of t-options.

e.g.

<span t-esc="5" t-options="{'widget': 'char'}" t-options-widget="'float'" t-options-precision="4"/>

the t-options-xxx overwrite the dict. The rendering became:

<span>5.0000</span>
2018-08-13 17:09:28 +02:00
Christophe Matthieu db8ed9aa47 [IMP] report: render report without editable mode
Before this change, the reports were generated in editable mode for branding
to be applied. The branding is used to cut the report and add on each
selected record for generating the pdf.
Applied branding and editing options takes a useless time and branding
was also applied by widgets even if branding was not requested.
2018-08-13 17:09:28 +02:00
Florent de Labarre d319160d3d [IMP] models: keep a consistent order for record metadata
When reading the metadata of a record, ensure the order is consistent.
The retrieval of ir.model.data is now done using an order=id query

Use the ORM to retrieve ir.model.data instead of making an SQL to clean old
code (introduced at b3b22afc68)

Closes #25658
2018-08-13 16:44:08 +02:00
Dharmraj Jhala 5038f068c0 [IMP] event: usability improvements
This commit includes various improvements:
* 'Event' menu is moved under 'Reporting' menu and will be visible without debug
  mode
* view sequence has been changed to pivot, graph, list, form
* new filters have been added:
    - Unconfirmed
    - Confirmed
    - Attended
    - Registration Date
    - Event Start Date
    - Attended Date

Task 1854339
2018-08-13 16:32:40 +02:00
Dharmraj Jhala 03ed4470b4 [IMP] doc: document timeline attribute on cohort view
Task 1854339
Closes #25576
2018-08-13 16:32:40 +02:00
Yannick Tivisse 08b0bc2f71 [IMP] account: Increment new account code till there's no conflict
Purpose
=======

Since https://github.com/odoo/odoo/commit/db3e40396232f41d86ec0c5f90e783e77f3e9510
we try to increment the account code on account duplication.

Now with this commit with increment the code till there are no other account with
the same code in the same company.
2018-08-13 16:00:21 +02:00
Francois Volral 914bbd363c [FIX] orm: Fix a bug in _read_group_fill_temporal.
_read_group_fill_temporal was returning a None value instand of a [] when its
'data' parameter was an empty array, resulting in crash in graph_view.
2018-08-13 15:45:38 +02:00
Arnold Moyaux 2e5c97c561 [FIX] mrp: remove sequence data
Warehouse's routes, locations, picking types and
sequences are now generated on create or with a post
init hook for exisiting warehouses before module installation.

Before the init hook, warehouses created before mrp module installation
do not have a specific sequence number for manufacturing and they
shared the same sequence production created in data.
2018-08-13 15:38:34 +02:00
Arnold Moyaux 0b73f17aa2 [IMP] stock: order rule by sequence,id instead of sequence,name
The purpose is to define a better sequence order by default.
Rules's name generation is base on their location and warehouse name.
Since locations order is not always the same than the alphabetical
order, we would rather use the id.
2018-08-13 15:38:34 +02:00
Arnold Moyaux 5acb048947 [IMP] stock: decrease reception route sequence
It improves default rendering for 2d routes representation
included in commit 94a3919d09
2018-08-13 15:38:34 +02:00
Arnold Moyaux 51ae8a341b [IMP] stock: remove apply on warehouse for crossdock route
It should was useless since no warehouse was selected on it.
Also the route was already applicable for product and product
category.
2018-08-13 15:38:34 +02:00
Arnold Moyaux 107b275a18 [IMP] mrp: log activity
Pickings/MO/SO/PO can be linked. Only the increased quantity is
propagated between documents. However their ordered quantities can
also be decrease or they can be cancel. In this case an activity
is created on impacted documents in order to describe the situation
and inform the user that a manual action is probably require.

Also in order to propagate the increased quantity from a MO, we have
to do important modification in MRP and we want to avoid doing it before a
major release. That's why increased quantity on a MO also work with
activity at the moment.
2018-08-13 15:38:34 +02:00
Arnold Moyaux c5b3f41fbd [IMP] mrp: new procurement group for MTO manufacture product
The purpose is to split up the supply chain in different group.
Currently if a user create a SO with a MTO manufacture product
that use MTO/buy components.
SO cancellation will:
- Cancel all the pickings including pickings between MO and suppliers.
- Log an activity on the MO but not cancel it.

We prefer cancel all transfers between SO and MO when the SO is cancel.
Cancel all the transfers between MO and suppliers when the MO is cancel.

Create a new procurement group when the _run_manufacture method is call
allows to achieve this behavior.
2018-08-13 15:38:34 +02:00
Arnold Moyaux bf592f7b86 [FIX] stock: Only search routes on warehouse if warehouse is set.
It could happens that search_rule do not receive a warehouse_id.
In this case warehouse.route_ids does not work.
2018-08-13 15:38:34 +02:00
Arnold Moyaux 1e160dffd3 [IMP] stock, mrp: picking before and after manufacturing
Currently MRP do not handle multi locations for components. In order to
be able to use both feature at the same time, we could:
- Improve mrp in order to handle multiple stock.move.line for a
componenet stock.move
- Add a rule that allow to bring all the good from multiple location to
a single location. (was already possible but it requires some
configuration)
This commit introduce a checkbox on the warehouse in order to
automatically configure all the routes/rules/locations/picking_types,...
necessary to bring all the components to a single location before
running the manufacturing order.

Technically it also refactor some stock_warehouse.py methods in order to
easily override the picking_type, rules and routes creation.

Thank to Hetashree Chauhan <hch@odoo.com> for his help.

task_id: 27785
2018-08-13 15:38:34 +02:00
Mitali Patel 177981b09f [FIX] sales_team: remove strptime as date fields now return date objects
Since https://github.com/odoo/odoo/commit/960360afe478a8f7b9c456721b5591154952a37d
date and datetime fields return date and datetime objects instead of
strings.

Task : #1873933
Closes #26308
2018-08-13 15:17:39 +02:00
Nicolas Bayet 93c92c72e8 [IMP] account: Hide 'Import' button on bank statements list view
Purpose
=======

It's way more complicated than the dedicated import mechanism on the dashboard

NB:
There are still no way to hide the import button in a generic way.
This kind of ugly hack has already been done in https://github.com/odoo/enterprise/blob/master/sign/static/src/js/sign_backend.js#L53
This should be removed as soon as such a mechanism arrives.

TaskID: 1861619
2018-08-13 15:00:49 +02:00
ThanhDodeurOdoo 693e59a9b0 [FIX] mail: move SCSS rule to enterprise 2018-08-13 14:59:47 +02:00
Nicolas Bayet fa7124920d [IMP] account: Reorganize menuitems
- Resequence menuitem to improve the structure.
- Relabel some menuitems to improve readability

TaskID: 1850716
2018-08-13 14:56:53 +02:00
sri-odoo 6153d65664 [REF] base: partners, use new record design 2018-08-13 14:46:47 +02:00
sri-odoo 1de38243a9 [FIX] base: apps list alignment 2018-08-13 14:46:47 +02:00
sri-odoo 6494d115e5 [FIX] web, mail: navbar & systray colors + badge alignment 2018-08-13 14:46:47 +02:00
sri-odoo 323cfddcde [FIX] web: BS4, main component grayscale
BS4 blue-ish grayscale is ok for text, borders and shadows but it's too saturate for main components with solid background (eg. control panel and body bg).
This commit will use a desaturate version of the same colors.
2018-08-13 14:46:47 +02:00
sri-odoo 460e1a2ef4 [REF] hr_attendance: replace user's availability icon 2018-08-13 14:46:47 +02:00
sri-odoo 5776b73a54 [REF] hr: employees kanban, use new record design
Use new record design + remove useless (in kanban) fields
2018-08-13 14:46:47 +02:00
sri-odoo 0a29522da6 [IMP] web: kanban record, fill image design
Add a new record layout that make the image compensate the record
padding and fill the available space.
2018-08-13 14:46:47 +02:00
jem-odoo 58e4a58427 [MERGE] hr_timesheet: log timesheet in any time UoM
Since uom management has been extract in a separated module, we
can now add the possibility to use it without product.

This commit brings the ability to record the timesheets in
an different UoM than 'Hours'. The user can now set an encoding
UoM for its timesheet on the company. This will display the
timesheet field `unit_amount` with a different widget.
For instance, timesheeting in hours will still use
the traditionnal float_time widget, when timesheeting in 'Days'
will displayed a toggle button with a range of defined possible
values.
The widget used by UoM is customizable on the UoM. The `unit_amount`
field should now be decorated with the 'timesheet_uom' widget.
This one will bind the correct widget (float_time, float_toggle, ...).
If the encoding UoM has no widget associated, the fallback will
be 'float_factor', using the uoM converstion factor.

Everything will still be stored in the database in 'Hours' (the
UoM set on the `project_mode_time_id` field on the company).

For more details, please have a look at the subcommits.

Task #39079
Closes #24893
2018-08-13 14:40:28 +02:00
jem-odoo 8db463d124 [MOV] analytic: move uom field from account to analytic 2018-08-13 14:39:50 +02:00
Nicolas Bayet 71bf212a21 [IMP] account_asset: Set default analytic accounts and tags on AML
Purpose
=======

Be able to speficy analytic accounts and tags on the account_assets module
that should be set on the generated account move lines.

TaskID: 1868221
2018-08-13 14:36:40 +02:00
Nicolas Bayet c410b7b4e7 [IMP] web: Add option on 'Datepicker' to warn when setting date in the future
Purpose
=======

There's no generic way to display a warning message if the user tries to set
a date in the future.

Specification
=============

Add this new feature on the datepicker (in web module), and use it account. For
example for the invoice date on the invoice/vendor bills form view.

TaskID: 1868221
2018-08-13 14:36:36 +02:00