Commit Graph
100643 Commits
Author SHA1 Message Date
Aaron Bohy 5ba53f3b11 [FIX] mail: display user status in chat windows 2016-02-08 08:29:53 +01:00
Aaron Bohy 79a8eeb17d [FIX] mail: unread counter on new message in non pinned DM
When a new message arrived in a non pinned DM, the unread counter was
incremented twice ; once because the channel info (along with its unread
counter) was fetched from the server as the channel wasn't in the JS cache yet,
and once when adding the message in the JS.

With this rev., we only increment the unread counter when a new message arrives
if its channel is already in the JS cache.
2016-02-08 08:29:53 +01:00
Aaron Bohy bc2d86e00f [FIX] mail: correctly compute unread messages
Two problems occured:
 - when the user hadn't seen any messages of a channel, the seen_message_id
   was null and doing seen_message_id < msg.id to retrieve all messages
   received after the last one seen didn't return any message (null < x is
   always false)

 - messages sent by visitor on the livechat doesn't have any author_id, so,
   again, doing msg.author_id != partner_id is always false, and as a
   consequence, server-side, the messages sent by visitors were always
   considered as read
2016-02-08 08:29:52 +01:00
Aaron Bohy 2b43624666 [FIX] mail: don't display subject of messages written in a chatter
This was working fine until rev. 4bab99bd which accidentaly changes the
condition.
2016-02-08 08:29:52 +01:00
Aaron Bohy 377bcd202f [FIX] mail: overlapping calls to get_channel_preview
Problem occured when the first call to get_channel_preview was directly
followed by others, before the channels_preview_def was resolved. In that case,
the other calls all returned an empty array, as only the channels_preview
array was only filled with the RPC result for the first call to
get_channel_preview (the one which initiated the RPC).
2016-02-08 08:29:52 +01:00
Aaron Bohy 021f9aeec7 [FIX] mail: systray items must wait for chat_manager
Those items might have been rendered and inserted into the DOM before the chat
manager initialization was completed. As those items rely on chat manager's
data, they should wait for it before executing their action (inbox redirection
and channels preview display).
2016-02-08 08:29:52 +01:00
Odoo Translation Bot f2146d360d [I18N] Update translation terms from Transifex 2016-02-07 00:33:44 +01:00
Goffin Simon dda8e2211a [FIX] calendar: order of calendar contacts
When displaying calendar contacts in calendar view, the contacts
have to be ordered by name.

opw:666397
2016-02-05 16:17:53 +01:00
Joren Van Onder ca3f3552f8 [FIX] pos_cache: take into account language of the compute user
Otherwise you'll always end up with untranslated product names.

Fixes #10736
2016-02-05 15:29:14 +01:00
Géry Debongnie bc03c915d4 [FIX] mail: various UI fixes
- correct template for undo snackbar
- better padding for chat windows
- recent messages now display 'now' instead of 'a few seconds ago'
2016-02-05 15:23:27 +01:00
Géry Debongnie 9e31b5de2a [FIX] mail: discuss notifications small fixes
- discuss notifications are always sent natively if possible
- clicking on native notifications focus the tab
- clicking on native notifications closes them
- granting notification permissions will display a confirmation
  notification
2016-02-05 14:09:19 +01:00
qdp-odoo ce784ae933 [FIX] account: default value of refund_sequence boolean on journal is False, as the most common practice seems to share the same numbering for invoices and refunds 2016-02-05 12:32:26 +01:00
qdp-odoo f7b1466f7e [FIX] account: starting amount of bank statement was considering only closed statements which is wrong (+ made small refactoring for the default_value and the onchange) 2016-02-05 12:27:32 +01:00
Thibault Delavallée 8aff53733b [FIX] tools: mail: sanitizer email escape
The sanitizer escapes email addresses contained in its source html to
avoid having it being discarded. Indeed the lxml cleaner considers them
as invalid tags and remove them.

However this escaping does not take into account email-like patterns
contained in cite attribute present on blockquote, del, ins or q.

This could lead to blockquote tags being escaped and therefore wrongly
displayed. This is now fixed.
2016-02-05 11:51:18 +01:00
Thomas Groutars 7c432c8b65 [FIX] Fix get_default_ method decorator and definition
In sale.config.settings, the method get_default_sale_config has api.multi decorator.
However, the method definition should be def get_default_sale_config(self, cr, uid, fields, context)
(see https://github.com/odoo/odoo/blob/9.0/openerp/addons/base/res/res_config.py#L534 ).
The api.multi decorator results in the model being browsed with fields as ids, which results in that kind of queries:

select * from sale_config_settings where id in ('generate_sales_team_alias')

This change corrects the method definition to fix that.
2016-02-05 11:24:06 +01:00
Nicolas Lempereur 7c11d4e70f [FIX] web_editor: minor tweaks IE11
In IE11 the values can be not string (for example a number and so not
have .indexOf method), but then there will no be !important bits and we
can just ignore this feature (which check if an overriding rule has an
!important flag).

There was another edge case when getting a "" set style, we get undefined.

opw-667917
2016-02-04 16:50:22 +01:00
Denis Ledoux 9c594cb3cd [FIX] website: optimize SEO in other languages than the default one
When connected as a website manager,
in another language than the default
website language,
it was not possible to use the optimize
SEO feature, because it needed
variables that were not available if the website
was considered as translatable only,
not editable. This is the case
when you are in any other language
than the default website language,
`editable` is `False`
and
`translable` is `True`.

This is a change of behavior compared to Odoo 8.0,
where `editable` was considered to `True`
even if you were only editing the website translations.

opw-668632
2016-02-04 16:35:34 +01:00
Martin Trigaux ff3184ed82 [FIX] packaging: include eml files in builds
The file addons/crm/test/customer_request.eml is used in
addons/crm/test/crm_lead_message.yml

Fixes #10750
2016-02-04 14:16:43 +01:00
Goffin Simon 0923d1609d [FIX] purchase: _compute_qty_received
Copied from _get_delivered_qty in addons/sale_mrp/sale_mrp.py
When a product with a BOM is delivered, the delivered qty must
be the produt qty set in the PO line.

PS: There is no dependencies between mrp and purchase

opw:668572
2016-02-04 14:06:53 +01:00
Yannick Tivisse 1723ed5842 [FIX] hr_holidays: Display the remaining leaves on Leaves Analysis
There was a domain on the action to display only the leaves and not
the allocations. Because of this, it was impossible to display the
used leaves, the allocated leaves and the remaining leaves on the same
view, which is frustrating for a HR when he wants to reports some leaves
from a legal year to another
2016-02-04 11:59:43 +01:00
Joren Van Onder efe263280d [FIX] point_of_sale, pos_restaurant: temporary orders
pos_restaurant creates temporary orders when splitting the bill. This
ensures those are never saved to persistent storage. As soon as the user
clicks on the pay button, the order is not considered temporary anymore
and will be saved.

Closes #10767
Fixes #10350
opw-666141
2016-02-04 11:50:21 +01:00
Jérome Maes cf8b05a16d [FIX] website_theme_install : bad method signature
In new api, the context in encapsulated and propagated with 'env'. There is no need to add in the signature. Method decorated with api.multi/api.model replace method(self, cr, uid, context).
2016-02-04 11:46:04 +01:00
Goffin Simon 703a2faf78 [FIX] project_timesheet: Remaining Hours
The remaining hours of a task must be equal to the planned hours
if this task is not linked to a account.analytic.line

opw:667309
2016-02-04 09:28:48 +01:00
Denis Ledoux 9fa73d10cf [FIX] account: set payment_method_code as readonly
The payment method code is not supposed to be changed
from an `account.payment`.

Besides, this field is only used for technical reasons,
as stated:
```
Technical field used to adapt the interface to the payment type selected.
```

There is therefore no reason to not set it as readonly.

Not setting it as reandonly could lead to a `write`
operation on the `account.payment.method` with the value
of the code, even if this is already that one set, and
such an operation could be prevented by the access rights.

opw-668624
2016-02-03 18:35:43 +01:00
Olivier Dony 93e8bf8ccf [MERGE] Forward-port saas-6 up to 1f022a0b4a 2016-02-03 16:55:41 +01:00
Olivier Dony 1f022a0b4a [MERGE] Forward-port 8.0 up to rev. 67a63e2cc9 2016-02-03 16:53:30 +01:00
Olivier Dony 67a63e2cc9 [MERGE] Forward-port 7.0 up to rev. cb609bd425 2016-02-03 16:42:29 +01:00
qdp-odoo 967be70c52 [FIX] account: tax of type 'group' wasn't propagating correctly the base of computation for next taxes (in case one of the children had the field 'Affect Base of Subsequent Taxes' set). Fixes issue 641078 2016-02-03 16:37:41 +01:00
Géry Debongnie 5465dccd69 [FIX] mail: prevent the composer to break layout in client action
The composer can grow vertically.  It will eventually grow out of the
chat content, which breaks the layout.  This commit fixes the issue.
2016-02-03 14:36:30 +01:00
Géry Debongnie 90d4f76100 [FIX] mail: users can now reply directly in documents from channels
A missing feature in discuss was the possibility to directly reply to a
message from a channel without opening the document.  This commit add
that feature.  Now, there is a small 'reply' icon in channels (including
inbox/starred) if the message comes from another document.  This icon
opens an extended composer, which will post the message in the document
chatter.
2016-02-03 14:36:30 +01:00
Thomas Groutars cc36e03ddc [FIX] product_visible_discount: wrong argument type
Fix call to v8 method with wrong argument type

Closes #10745
opw-668544
2016-02-03 13:30:17 +01:00
Martin Trigaux aca28c82b4 [FIX] website_sale: do not compute price of every pricelist
This controller was very slow as not providing a pricelist computed the price of
all products of all pricelists.
Instead only fetch the prices for the useful products.
2016-02-03 12:05:42 +01:00
bima d01ecb6e79 [FIX] stock: wrong variable used in _handle_renaming
Could incorrectly rename the stock.location.path objects, and in case
the route has push_ids but no pull_ids would crash the method entirely.

closes #10747
2016-02-03 09:55:43 +01:00
Yannick Tivisse 1fb9227893 [IMP] stock: Missing kanban view on all stock.picking views from dashboard 2016-02-03 09:33:45 +01:00
Nicolas Martinelli b6250eb7f0 [FIX] account: filter taxes
In a multi-company environment, a user from company A which is a parent
of the company B has access to taxes from both companies. The
consequence is that the method _set_taxes will automatically add the
taxes from both companies.
2016-02-03 08:28:34 +01:00
Nicolas Martinelli 932a83de32 [FIX] account: forward port typo
type is not redefined, so this comparison cannot work. Moreover, a lucky
combination made the test pass, while they should not have.

opw-667935
2016-02-03 08:28:34 +01:00
Olivier Dony cb609bd425 [FIX] tools.misc: log errors when parsing fails 2016-02-03 02:25:09 +01:00
Olivier Dony 709323f071 [MERGE] Forward-port saas-6 up to 6562309927 2016-02-03 00:46:18 +01:00
Olivier Dony 6562309927 [MERGE] Forward-port 8.0 up to e8d06f7b20 2016-02-03 00:44:04 +01:00
Olivier Dony e8d06f7b20 [MERGE] Forward-port 7.0 up to bdbcbea285 2016-02-03 00:40:27 +01:00
Olivier Dony bdbcbea285 [FIX] marketing_campaign: incorrect field accessor 2016-02-02 22:43:39 +01:00
Olivier Dony cc724c2e61 [FIX] base: centralize custom data serialization for builtin types only 2016-02-02 22:42:31 +01:00
Olivier Dony 000c681f1e [FIX] ir.values: remove redundant deduplication logic
Handling update/create of existing values is already
handled by ir.values.set() itself.
2016-02-02 19:49:09 +01:00
Olivier Dony f3496dc233 [FIX] ir.qweb: access rights and corner cases for changes in #9978
Method `is_css_preprocessed()` introduced by #9978 at revision
79f13a2aaf might fail when the
user/visitor did not have sufficient access rights to read
the cached assets (depending on ir.attachment ACL)

In addition an empty cached asset could trigger a corner case.
2016-02-02 19:16:28 +01:00
Christophe Simonis 588c1efea6 [MERGE] forward port of branch saas-6 up to d613843 2016-02-02 18:37:34 +01:00
Christophe Simonis d6138430e9 [MERGE] forward port of branch 8.0 up to 8848af7 2016-02-02 18:32:46 +01:00
Xavier Morel 8848af76f0 [IMP] account: recordset calling conventions for fixed has_group 2016-02-02 18:28:23 +01:00
Xavier Morel ccb0f6db61 [FIX] base: has_group behaviour under the new API
While the signature makes sense in an old API context (sort-of) it's
very easy to misuse in a new API context as one'd expect `has_group` to
use the subject (recordset), not the user in the environment, compounded
by ``env.user`` being browsed as administrator, resulting in the
"obvious" ``env.user.has_group(foo)`` checking if the
administrator (rather than the current user) has the specified group.

Adds a divergent v8 version of has_group which first checks if it's
called on a non-empty recordset, and in that case use the recordset id,
otherwise fallback on the context user (to handle new API conversions
which used the "correct" call convention rather than the obvious one).

fixes #9649
2016-02-02 18:28:23 +01:00
Simon Lejeune a62597e1fa [ADD] ir_qweb: test less assets invalidation in debug mode 2016-02-02 15:24:51 +01:00
Simon Lejeune 79f13a2aaf [REF] ir_qweb: optimize assets compilation in debug mode
Mainly by moving the authority to handle the ir.attachments records
for Less and SassStylesheetAsset from the asset to the bundle.

We introduce a method `is_css_preprocessed` that will check if the
less/sass assets contained in a bundle already have ir.attachments
records. On top of that, it'll check if these existing records
need to be invalidated by comparing the last modified date of the
file and the __last_updated field on the record. If it is the case,
we chose to unlink all the less/sass attachments from the same
bundle.
2016-02-02 15:24:51 +01:00