Commit Graph
103915 Commits
Author SHA1 Message Date
Josse Colpaert 91e2dca945 [FIX] mrp: working_state should depend on time_ids when we just add one, OEE: efficiency -> effectiveness 2016-07-25 12:35:44 +02:00
Aaron Bohy f7703c5d9b [FIX] web_tour: tips activation when a modal is open
When a modal is open, we only activate tips that are inside the modal.

The former solution didn't work when the tip's selector contains ','
(often used when the selector is different in community and enterprise,
e.g. selectors for apps), because the modal restriction was only
applied on the first part of the selector.
2016-07-20 17:59:48 +02:00
Aaron Bohy 0a8ec45769 [IMP] web_tour: add button to consume all tours in debug_manager
Changes the api of the consume method on the web_tour.tour model so that it
now takes in argument an array of tour names instead of a single tour name.
2016-07-20 17:59:48 +02:00
Simon Lejeune d1cd293ece [FIX] web: session_info: introduce is_superuser key
This is done in order to enable the tour service only for the
superuser. Commit 6ef1644a7b changed the meaning of `is_admin`
to achieve this but broke the fact that some features of the debug
manager are available to admin and not only to the superuser. Anyway
a `is_admin` key should mean that the user is in the admin group.

We could have checked client side that the uid is equal to 1 but
adding a `is_superuser` key is more elegant and easier to grep.
Also fix the only occurence of a uid check in the weblcient.

This reverts commit 6ef1644a7b.
2016-07-20 14:16:01 +02:00
Simon Lejeune 6ef1644a7b [FIX] web: session_info: is_admin check
The tour mechanism displays a tour if the `session.is_admin` key
is set to True. For this key to bet set to True, you need to be
in the system group.

Default options adds the system group to any created user, however as
there aren't any ir.model.access rule defined on the `web_tour.tour`
model, when you try to login as this created user, you get a traceback.

As the only way to reach a `web_tour.tour` record is to have the
superuser_id, update the `is_admin` condition accordingly.
2016-07-19 17:49:37 +02:00
qsm-odoo 5bfcb697c4 [FIX] website: remove useless extra trigger in banner tour
The tip does not have to wait for this extra_trigger to show up.
Also, waiting for it seems to induce some bugs on chrome under
certain screen sizes, so best to avoid them.

Alse reduce the size of this tip as it is too big for small screen
sizes.
2016-07-19 15:09:47 +02:00
qsm-odoo 0d6527c901 [FIX] sale: correct tour step which uses wrong data-menu-xmlid
+ Hide useless tip in community
2016-07-19 14:10:28 +02:00
qsm-odoo e01cb8f717 [FIX] web_editor: prevent adding snippets by mistake
* Start dragging after the mouse move of some distance
* Cancel drop if the user drops a snippet in the snippet bar
2016-07-19 11:55:02 +02:00
qsm-odoo 19b4902c71 [FIX] web_tour: force tooltip content font style
Force tooltip content font style (size, family, line-height, weight)
so that it does not depend on where the tooltip is in the DOM.

This fixes a problem where the style changed when opening/closing the
tooltip. Indeed, the content dimensions, computed in javascript when
the tooltip is closed were wrong because of the style and the opening
/ closing rely on these values.
2016-07-19 11:55:02 +02:00
qsm-odoo a1c6e7243c [FIX] website(_blog): review end of tours banner and blog
Tour blog ended with forcing the user to click on a fake element. So
the end of tour blog and banner had to be changed.
Also, the tour step could appear in edit mode which is not what we
wanted.
2016-07-19 11:55:02 +02:00
qsm-odoo 25ce72d7a1 [FIX] website: remove theme-dependant tour step description
A tour step mentionned the "features" block and selected the nth
snippet. The problem is that the nth snippet is not the features
block for every theme.
2016-07-19 10:53:46 +02:00
qsm-odoo a3585b84b5 [FIX] website(_*): stop launching old tours on installation
On website/theme installation and other website_* module installation,
an action was triggered to launch tours. These tours are now used only
for tests and should not be used as onboarding anymore.

Note: in master these tours will be removed to use the new test system.
2016-07-15 17:47:03 +02:00
Christophe Simonis c16d5bc750 [MERGE] forward port branch saas-11 up to 87e9639 2016-07-15 16:35:48 +02:00
Christophe Simonis 5858dda75f [MERGE] forward port branch saas-11 up to a62b8cf 2016-07-15 16:34:41 +02:00
Olivier Dony 87e9639a97 [FIX] website_event: correct typo in new API conversion
event.event's field is 'country_id', not 'country'

Cfr 616f294786
2016-07-15 14:02:01 +02:00
Christophe Simonis a62b8cfaeb [FIX] hr_timesheet: add missing icon for Timesheets main menu
This icon was remove by 05a143a416 but is
still referenced by the menu entry.

This is also a backport of 3843b86fef.
2016-07-14 19:34:35 +02:00
Olivier Dony f5eba9e4d8 [FIX] web: repair grouping on date fields in list view
This is a temporary workaround, which probably deserves
further thinking by @ged-odo, as the root cause
stems from commit 96bf5b2656

The problem is that the list view looked for composite group_by
keys such as "create_date:month" within `fields_get`, which
only contains true fields.
2016-07-14 18:48:08 +02:00
Denis Ledoux 18dc5b3b87 [FIX] web: default many2many tags color
When there is no `color` field on the model
e.g. On invoice line taxes
The color class to apply on the badge was set to
`o_tag_color_undefined`
which doesn't exist. It must be set
from `o_tag_color_0` to `o_tag_color_10`
in order have a color.

Because of this, the taxes in the invoices lines
were not visible, because they were written in white
on a white background.

This has been broken by the below revision:
fe66472e2c
removing the or statement (`||`) to set a default
color for models not having a `color` field.

We choose to set `10` as default value, so the color
remains the same compared to the previous release
(light grey). However, if the new behavior chosen
by the usability is to have these in black, it should then
be changed to `0` again.
2016-07-14 18:38:29 +02:00
Christophe Simonis 1fca5e01cb [MERGE] forward port branch saas-10 up to 156dee2 2016-07-14 18:17:30 +02:00
Christophe Simonis 156dee2aec [MERGE] forward port branch 9.0 up to fd9eb2e 2016-07-14 17:17:54 +02:00
Olivier Dony 6d3cf9c649 [FIX] website_mail_channel: re-add import dropped by API migration
The migration to new API dropped `from openerp import tools`,
but it was still used.

See also 8250762fe8
2016-07-14 17:07:44 +02:00
Olivier Dony a78c2e3d39 [FIX] website_mail_channel: fix datetime typo in new API migration
The migration to new API changed `import datetime` to
`from datetime import datetime`, subtly breaking existing
calls.

See also 8250762fe8
2016-07-14 16:52:40 +02:00
Denis Ledoux 78fee4b6b0 [FIX] website_sale: "From website" filter
This filter must be added in the regular searchview,
and not have his own search view.

Without this:
 - view_sales_order_filter_ecommerce is a not search view
 for the sale orders, having the same priority than the regular one,
 and therefore this view can be loaded by default for other menus
 (In this case, this was for the menu Website Admin > Orders).
 e.g. Clicking on the `Sales` stat button on a contact no longer
 filtered the orders of this contact, but displayed all the orders,
 because it was this view which was loaded instead of the regular one.
 - In Website Admin > Orders, it was simply not possible to type a string
   and search for it in the search bar.
2016-07-14 16:37:28 +02:00
Christophe Simonis fd9eb2e481 [MERGE] forward port of branch saas-6 up to e928c60 2016-07-14 16:23:22 +02:00
Christophe Simonis e928c6003a [MERGE] forward port of branch 8.0 up to 17a1304 2016-07-14 15:46:28 +02:00
Denis Ledoux 8d2d741db3 [FIX] mass_mailing: do not inherit a view on a string attribute
A string attribute value can be translated,
and therefore the inherit broken if the term is indeed
translated.

This was the case for this term "Tracked link" in the Dutch
language, the "Tracked link" term of the inherited view has
been translated, and the inherit was therefore broken as
it couldn't find the given node in the base view due to the
fact this term was translated.

opw-683128
2016-07-14 12:25:02 +02:00
Ronald Portier 17a1304285 [FIX] hr_timehseet_sheet: drop view before creation
When the schema of a view change (e.g. drop of column), the "CREATE OR REPLACE"
will not be enough and dropping the view is required.

Fixes #12754
Closes #12756
2016-07-14 11:42:52 +02:00
Xavier Morel 5bb0933a52 [REVERT] 7930c3f86
Faster is nice, working is better, sale_timesheet, this commit breaks
the tests and the installation of multiple modules.
2016-07-14 09:57:17 +02:00
Goffin Simon 46c3c721fc [FIX] sales_team: _get_default_team_id
The domain term '('member_ids', 'in', False)' should use the '=' or '!=' operator.

sentry:90136545
2016-07-14 09:12:13 +02:00
Goffin Simon e71d136d6f [FIX] sale: making an advance payment in percent
When making an advance payment in percent, the function onchange_advance_payment_method
set the Down Payment Product to False. Then each time an advanced payment in percent
was made, a new down payment product was created and set in sale.config.setting in the field
deposit_product_id_setting.

Now the function onchange_advance_payment_method let the Down Payment Product
even if the payment method is in percent.

opw:683167
2016-07-14 09:01:58 +02:00
Christophe Simonis 9b7bc217a2 [FIX] base: avoid applying inherited view twice
Use the `|=` operator to deduplicate view ids.
2016-07-13 20:42:43 +02:00
Christophe Simonis 7930c3f86e [IMP] base: ir.ui.view inherit search during module update
During module update, we should only consider views of already
loaded modules. This filter is done by searching on xmlids of views.
We should also search for explicit view ids (current module is not yet
marked as loaded)

However, by doing this `OR` condition, the generated query is not
optimal and forbid postgresql to use the composite index
`ir_model_data_model_res_id_index` on `ir_model_data` table.
This is a performance issue for databases with a lot of ir_model_data rows.

Use 2 quicker search() to avoid this problem.

This only affect the module update. Normal view loading is unchanged.
2016-07-13 19:19:11 +02:00
Damien Bouvy 7c2c169906 [FIX] base: mixing ids and records
Browse needed.
2016-07-13 17:27:24 +02:00
Christophe Simonis a039fc509b [MERGE] forward port of branch 8.0 up to 9650249 2016-07-13 17:26:44 +02:00
Damien Bouvy 8cad4ce011 [FIX] web_settings_dashboard: user count consistency
Odoo S.A. invoices only 'non-share' (internal) users; the default
filter on the user list view does the same thing. It makes little
sense for the user counter to count all share users.
2016-07-13 16:58:31 +02:00
qsm-odoo 9b77d76e71 [FIX] web,website,point_of_sale: session.debug value
Now that the debug URL parameter can be equal to "assets", the session
debug variable has to be updated to not only be true or false. Now, its
value is false if the debug parameter is not specified in the url and
a the URL parameter string value otherwise (or 1 if the value is an
empty string).

Also modify all redirection which kept the debug mode to also keep
=assets. Use the $.param.querystring function.
2016-07-13 16:13:04 +02:00
Simon Lejeune 05a143a416 [REF] hr_timesheet, hr_timesheet_sheet: hr_timesheet is the application
* switch application flag between `hr_timesheet_sheet` and `hr_timesheet`
* renamed `hr_timesheet` application name from "time tracking" to "timesheets"
* move the icon from `hr_timesheet_sheet` to `hr_timesheet`
* removed unused icon from `hr_timesheet`
* renamed `hr_timesheet_sheet` application name from "timesheets" to "timesheets / attendances"
2016-07-13 15:07:56 +02:00
qsm-odoo 60e446351c [FIX] web_tour: update after consume (sometimes no mutation) 2016-07-13 14:46:23 +02:00
qsm-odoo 2a56e8941b [FIX] web_tour: debounce mutation callback instead of throttle 2016-07-13 14:46:23 +02:00
Joren Van Onder c902437247 [FIX] barcodes: allow users to 'click' focused buttons with Return
Return key events don't get redispatched and even if they did, it
wouldn't work because 'fake' keypress events don't trigger native HTML
event handlers.

This should be safe because Return cannot start a valid barcode.
2016-07-13 13:58:50 +02:00
Joren Van Onder 4dc228d01c [FIX] stock: don't show empty Reserved group
We hide the quants_grp if the stock.move is in the draft state. In this
case normally the value of the string_availability_info will be empty
anyway, because the _get_string_qty_information function skips moves in
the draft state.

This is especially useful on small displays, because on there the string
attribute of the field won't be shown, so you just end up with a
Reserved heading with nothing underneath it.
2016-07-13 13:58:50 +02:00
pvy 65a1c0d060 [FIX] account: the period was wrong as it didn't take into account the 'not due' period 2016-07-13 11:23:43 +02:00
qdp-odoo bf999c168a [IMP] account: added 'form' mode in the action returned by clicking on the 'Journal Items' stat button on payments and bank statements, because it was so boring not being able to see the details or open the account.move from that view 2016-07-13 11:22:10 +02:00
qdp-odoo 2d91575b11 [FIX] account: cancelling a bank statement line linked to a payment SEPA or batch deposit should set it back to 'sent' state, not 'posted'. 2016-07-13 10:00:07 +02:00
Jairo Llopis 0529a7f9ba [FIX] tools: extract terms in correct folder
If two addons path have a common part in the folder name (e.g. `/home/alice/dev`
and `/home/alice/devodoo`), the `get_module_from_path` method may match the
wrong folder.
A file `/home/alice/devodoo/bob/models.py` would wrongly match `/home/alice/dev`
path (due to the lack of separator) and the returned module would be `odoo`
(`"odoo/bob/models.py".split('/')[0]`).

In such scenario, the translations of files (code, static folder, report) would
not be included in the exported translation file.

Force the module path to ends with a folder separator to avoid wrong matching.

Closes #12757
2016-07-13 09:43:38 +02:00
Jairo Llopis ee365bbf98 [FIX] modules: choose the right addons path
When launching a server with two similar addons path, e.g.:
- /home/alice/dev
- /home/alice/devodoo

launching the server in dev mode may crash due to the poor matching using
`path.startswith(...)` method which may make `/home/alice/devodoo/bob/main.xml`
match in addons folder `/home/alice/dev` and with a non-exitant local path
`odoo/bob/main.xml`.

Instead of relying on the name, use the `os.path.commonprefix()` method to match
on real paths and avoid partial matching.
commonprefix will only work if the folder name ends with the appropriate
separator (which is not guarantee for a user provided addons-path) so force a
trailing `/` using os.path.join(..., '')`.

Closes #12359
2016-07-12 17:21:50 +02:00
Damien Bouvy d7d07810aa [FIX] hr_timesheet_sheet: no product on employee
Some leftover code from before.

opw-683126

Courtesy of David Coninckx
2016-07-12 16:30:56 +02:00
Aaron Bohy ee4c808d2c [FIX] web: debug_manager: update when coming back with breadcrumbs
Before this rev., the debug manager's state was only updated when pushing a new
action but not when coming back to a previous action using the breadcrumbs.
So when the latter case happened, the debug manager was desynchronized with the
action manager and it allowed to edit an action that wasn't the current action.
2016-07-12 15:30:01 +02:00
Vincent Renaville c9b270c9a4 [IMP] l10n_ch: extend minimal chart of account. Was PR #12552. Courtesy of CamptoCamp 2016-07-12 12:15:57 +02:00
Damien Bouvy f600366092 [FIX] point_of_sale: correct previous fix
I inadvertently inverted the domains; silly me.
2016-07-12 09:26:01 +02:00