Commit Graph
99661 Commits
Author SHA1 Message Date
Géry Debongnie 2c84cd4181 [FIX] mail: various improvements/fixes
- display appropriate message when no results are found in a search
- don't display 'you have been invited' notif when creating private channel
- correctly join when a user was invited in a public channel
- display a message when a user join a channel through an invitation
- don't display subject for message of type notification (still a
  mystery why it happens in test.odoo.com for channel of type mailing)
- better heuristic on when to display message subject
- tweak sidebar text color (slightly whiter)
- add ... to the placeholder of the text area in the composer
- invert send and icons for attach/smiley in composer
- don't display 'read less' on expanded messages
- exclude livechat channels from channel mention suggestions
2015-11-27 11:47:34 +01:00
Aaron Bohy db8203c27a [FIX] base,hr,mail: prefetch mention suggestions
The purpose of this commit is to improve the overall performance of the mention
mechanism of the client action and chatter composer, by pre-fetching some data.

First, the employees are fetched at chat initialization (basically, at web
client initialization), if hr is installed.

Second, when focusing on the composer of a channel, the members of this channel
are fetched. In the case of a chatter, the members are already known as they
are the followers of the document.

When the user types a mention, we first display suggestions from the pre-fetched
partners, and we only perform an RPC when there are no more result matching the
search string. This RPC searches among user, and then partners if there aren't
enough matches.

A few side changes occurred:
  - auto_join set to True on user_ids field of res.partner to boost the query
    that searches partners that are users
  - the '/mail/read_followers' route now returns follower's email as well, as
    we need it for the mention;
  - a partner can now be mentionned several times in the same message;
  - mentionned partner previsualization has been removed, mainly because of
    the previous point, but also because it simplifies the code;
2015-11-27 11:47:34 +01:00
qdp-odoo 9ef3a9296d [FIX] account_bank_statement_import: raise proper error (osv not defined) 2015-11-27 11:05:12 +01:00
Denis Ledoux f9a462f3e2 [FIX] website: different assets_common according to user rights
The content of an asset can change according to which modules
are installed, but cannot change according to the user rights,
according to which user is connected.

Otherwise, the assets is re-generated  and stored
in the filesystem too often, which is against the
concept of the assets.

opw-657046
2015-11-26 18:08:42 +01:00
Nicolas Lempereur 8423a0df34 [FIX] http: clear environment on checked called rollback
If the current cursor transaction was not empty when using the check
called endpoint, at the first call the cursor would be rollbacked but
the environment could still have outdated values.

This was an issue for example when selecting the route would trigger
database insert, for instance when a model was used in the route and
this model had also translatable prefetchable fields with tokens not
already present in ir.translation

opw-652045
2015-11-26 16:57:03 +01:00
Nicolas Lempereur 9d012d2157 [FIX] tools, base: typo for t-translation 2015-11-26 16:56:53 +01:00
Goffin Simon e9dadadd07 [FIX] account: Bank statement reconciliation
The partial reconciliation can just be proposed on the last selected line when:
self.get("balance") * (last_line.debit - last_line.credit)<0
2015-11-26 16:53:12 +01:00
qdp-odoo 8aeae17d78 [REF] sale, sale_stock: added some comments to clear some aspects of the code related to the last changes on SO (salepocalypse) 2015-11-26 16:42:14 +01:00
qsm-odoo bbc67ec402 [FIX] web: export data according to domain
Some accounting model (i.e. account.tax) are redefining the ORM search
method, but with misordered arguments (placing count as fifth argument
instead of context).

For the export function, this lead to have the "context" variable
associated to the "count" function variable. As "count" is then
considered as True, the method returns the number of records instead
of the list of record ids. This then exported the last record (the
count'th one) instead of all the records that matched the domain.

The solution here is to explicitly give the context variable by name.
2015-11-26 15:57:17 +01:00
Nicolas Martinelli 53cb608b17 [FIX] purchase: missing string
Even if the field is used for technical purpose only, it is still better
to define a string for the translation.
2015-11-26 15:46:37 +01:00
Denis Ledoux 8be7eed9ca [FIX] sale, portal_sale: hide buttons for portal users
When a portal user opened his quotation form,
all buttons of the regular form were available.

They were not working, due the access rights,
but it's better to hide them.

opw-657654
2015-11-26 15:38:08 +01:00
Nicolas Martinelli 86015ac1c5 [FIX] purchase: add missing drop ship address
The drop ship address was missing from the view, making impossible to
specify the address where the products needed to be delivered.

The fix adds the missing field to the view, and make it visible (and
required) if the delivery must be done at a customer location.

opw-657054
2015-11-26 15:16:59 +01:00
Martin Trigaux dd8052a7ce [I18N] website_forum: reexport source terms
Remove incorrect term from calendar and add missing sentence
2015-11-26 15:12:31 +01:00
Nicolas Lempereur 971ea77a44 [FIX] website_forum: typo, entity need double escaping 2015-11-26 15:05:04 +01:00
Denis Ledoux 8c29e7f17a [FIX] sale: Sales filter
The filter `Sales` in the sales orders search views
was defined as
`[('state','in',('progress','Done'))]`
but
 - progress no longer exists. It's `sale` now.
 - `Done` is the label, `done` is the value

opw-657552
2015-11-26 15:02:00 +01:00
Géry Debongnie 7137891a8a [FIX] mail, im_livechat: correctly displayed message date
Messages are required to be displayed in a smarter way: relative to the
current date, if it's a recent message, or absolute if not.  This
commits rework most of the date processing code to comply with these
requirements.

Messages were preprocessed each time a thread is rendered, which is
stupid.  It should be preprocessed only when the message is created.
This was a small problem because livechat does not use the chat manager,
so a simplified version of the preprocessing had to be done.
2015-11-26 14:27:11 +01:00
Nicolas Martinelli bef0da3a7a [FIX] account: Total Receivable and Payable
The fields Total Receivable and Payable are calculated as debit-credit.
However, this leads to a wrong computation if, for example, a payment is
used to pay several invoices. For example:
- Create a customer invoice of 2500 USD
- Register a payment of 3000 USD
The Total Receivable will be 3000 USD instead of 500 USD.

At the same time, this commits changes the sign of the field. The help
depicts the Total Receivable field as "Total amount this customer owes
you". Therefore, one would expect that if the customer owes 250 USD, the
Total Receivable is 250 USD, not -250 USD.

The same logic applies to Total Payable.

opw-657053
2015-11-26 12:19:41 +01:00
Géry Debongnie 5b82c9ccb4 [FIX] mail: better heuristic for displaying origin channel 2015-11-26 10:25:44 +01:00
Géry Debongnie a98db07384 [FIX] mail: fix various search-related problems
This commit tries to correctly use messages from the cache instead of all
messages.  This means that we need to correctly add messages to the
domain-specific caches, and correctly invalidate them when necessary.

Also, to avoid increasing the algorithmical complexity of the process,
particular care was made to avoid scanning too many lists.  For example,
the channel caches have now a messages field, instead of message_ids.
2015-11-26 10:25:44 +01:00
Martin Trigaux 001e558178 [FIX] calendar: do not forwardport .pot content 2015-11-26 10:09:51 +01:00
Nicolas Martinelli 2f0135c820 [FIX] product: resets fields
applied_on:

The field applied_on in pricelist rules is not taken into account:
- In the price computation
- In the name computation

When creating a pricelist item, if you select (applied_on = Product)
first and set a product, then select (applied_on = Global), and save the
rule, the computation will still take the product_tmpl_id in the price
computation.

Instead of fixing the whole _price_rule_get_multi method, this patch
sets the fields that should not be taken into account to False.

compute_price:

Add a behavior similar to the applied_on field, to reset unnecessary
fields to zero when the computation method is changed.

Original idea from @tgr-odoo

opw-657148
Closes #9671
2015-11-26 09:57:55 +01:00
Cedric Snauwaert fd56268c6c [FIX] web: list_view, context when doing name_get call in m2m was not compute correctly 2015-11-26 09:43:21 +01:00
Christophe Simonis 32c7c31b40 [MERGE] forward port of branch saas-6 up to a73e292 2015-11-25 19:08:27 +01:00
Christophe Simonis a73e29255d [MERGE] forward port of branch 8.0 up to 1c5c255 2015-11-25 18:59:05 +01:00
Damien Bouvy 414c567dd1 [FIX] web_settings_dashboard: merge apps & enterprise panels
- Makes the panel less obtrusive and does not disrupt the
layout of the dashboard anymore.
- Use the global version info to save an extra RPC call.
2015-11-25 18:13:01 +01:00
Damien Bouvy 111b3838dc [FIX] mail: store expiration data w/ correct group 2015-11-25 18:13:01 +01:00
Damien Bouvy eee26f4454 [FIX] base: expiration date does not belong in the community edition
The expiration date will now be set when installing the enterprise
'web' module instead of at the init of the database since putting
an expiration date on a community edition database doesn't make sense.
2015-11-25 18:13:01 +01:00
Damien Bouvy 0a6edac151 [FIX] web, openerp: make the webclient edition aware
- Differentiate between the Community and Enterprise editions
in the version number. By adding this attribute on the global
odoo JS object in the web client bootstrap controller /web,
we can differentiate between versions easily on the client
side without extra RPC calls.

- Remove a couple of version-related RPC calls in case
the global version info is present in the JS environment

- Update "About" panel to display the edition info

- This commit also reverts 07fe5afc87
which implemented the idea in a more limited way.

Closes #9625
2015-11-25 18:12:42 +01:00
Martin Trigaux e8e5405d0c [I18N] Update French translation terms from Transifex
Fixes #9712
2015-11-25 17:22:26 +01:00
David Monjoie bc0521805a [FIX] hr_holidays: consistent leave allocations create
This window action did not open the create form
view as a leave allocation but as a leave request,
which was inconsistent with the very similar
open_allocation_holidays action. With the former,
the duration field was two dates. On the latter,
it was only a number of days, as it should be for
leaves allocations.
2015-11-25 16:56:05 +01:00
Aaron Bohy 0413cc9641 [FIX] web: display pager in SelectCreateDialog 2015-11-25 16:23:44 +01:00
Nicolas Martinelli 4d8ddabe63 [FIX] purchase: keep track of all procurements
Keep track of all the procurements in the field "Source Document" of the
PO.

opw-654424
2015-11-25 16:10:40 +01:00
Nicolas Martinelli 39f8b5aff7 [FIX] stock: error if not assigned
When the user validates a picking without going through the manual
reservation process, Odoo tries to assign the picking then performs the
transfer. However, if the picking could not be assigned, no pack
operation is created and the picking will simply be set to done.

The fix raises an error if the picking could not be assigned completely.
Another solution is to use a force_assign instead of action_assign, but
that could lead to the creation of negative stock moves without warning
the user. We therefore prefer to stay on the safe side and force the
user to manually handle the reservation.

Note: the original issue was that the Owner of the picking was not
copied on the quant when validating right away. The reason was that no
pack operation was created.

opw-654423
2015-11-25 16:09:16 +01:00
Darshan Kalola 1b714bdc6c [FIX] point_of_sale: fix 'Group of Taxes' calculation
There were still references in the POS to a child_ids field on
account.tax. This field was renamed in accounting v9 to
children_tax_ids. Because child_ids wasn't loaded anymore this meant
that child_ids on the taxes in the POS was always undefined. On top of
that the original code used Array.prototype.concat() assuming it
modified the array, when in fact it returns a new array.

All of this meant that group taxes in the POS were never calculated,
this resolves that.
2015-11-25 15:34:28 +01:00
Joren Van Onder b32355e9b7 [FIX] point_of_sale: fix forward port of currency displaying
This fixes the forward port of 5c9b4556e3
from saas-6, which was forward ported to 9.0 in
56a442e205.
2015-11-25 15:13:16 +01:00
Martin Trigaux 1c5c255186 [FIX] calendar: translatable date content
The time_display is present in a translatable email template but was not
translated. Added the missing term.

Updated .pot file for a few missing terms.
Removed base_calendar.pot that has no reason to be in 8.0

Fixes #9573
2015-11-25 14:36:55 +01:00
Denis Ledoux 2fd14db574 [FIX] stock: multi-company rule for stock.quant.
`stock.move` & `stock.product` have multi-company rules.
There is therefore no reason why `stock.quant` could not have one.

Besides, this could lead to access rights issues,
when a user went to the `Quants` list,
in Warehouse > Traceability > Quants,
while there were quants for products in a company different
than the user company.

opw-653188
2015-11-25 14:32:46 +01:00
Goffin Simon b2939537d9 [FIX] website_quote: using a quotation template with a fiscal position
When creating a SO with a quotation template, the lines created
with the quotation template must take into account the fiscal position
set on the SO to compute the right taxes.

opw:657015
2015-11-25 14:31:22 +01:00
Christophe Simonis 83f56a30a6 [FIX] website_sale: declare js function in the right module 2015-11-25 13:59:07 +01:00
Christophe Simonis 56a442e205 [MERGE] forward port of branch saas-6 up to dade7e3 2015-11-25 13:26:02 +01:00
Nicolas Lempereur 8d3bdf6b50 [FIX] project: IE11 issue with kanban overflow
In 6fd7fc9 the issue was solved in some instance, but there was still an
issue with the combination of IE11 / Odoo community / Overflowing content.

fixes #9696

related to opw-653477
2015-11-25 12:40:47 +01:00
Denis Ledoux dade7e3c17 [FIX] website_quote: confirmation email at payment.
`website_quote` overrides `payment.transaction`.`form_feedback`
the same way `website_sale` does,
in case `website_quote` is installed without `website_sale`.

Therefore, the revisions
 - 4adb4b8
 - 809e1a6

must be applied there as well.

opw-657432
2015-11-25 11:22:44 +01:00
Christophe Simonis 12d5b4168f [MERGE] forward port of branch 8.0 up to 8e1a5ad 2015-11-25 11:18:21 +01:00
Cedric Snauwaert d31b1ab2a7 [FIX] account: amount_residual_signed should be negative for refunds only 2015-11-25 11:02:32 +01:00
Nicolas Lempereur f5bd1cc922 [FIX] web: local var parent typo
fixes #8516

note: was already solved in enterprise with 7ab5075
2015-11-25 11:00:52 +01:00
Goffin Simon 15ff26c9f7 [FIX] website_quote: onchange_template_id
If a quotation template was used to create a SO, the default customer
taxes set on the product's line were not set on the SO lines.

opw:657015
2015-11-25 10:14:34 +01:00
Goffin Simon 0b52e8a887 [FIX] tools: html_keep_url
If an url is the label of a tag a, the htm_keep_url doesn't have
to treat this url.

opw:656821
2015-11-25 10:09:25 +01:00
Raphael Collet 8e1a5add38 [FIX] api: improve decorator returns to handle special cases, like method search
Add the possibility in the decorator to specify the `upgrade` and `downgrade`
functions that convert values between APIs.  Both function have the same API:

    upgrade(self, value, *args, **kwargs)
    downgrade(self, value, *args, **kwargs)

The arguments ``self``, ``*args`` and ``**kwargs`` are the ones passed to the
method, following its new-API signature.

Fixes #4944, #7830.
2015-11-25 09:59:35 +01:00
Olivier Dony 3b833b2039 [FIX] analytic: optimize name_search for large databases
On databases with a large number of res.partner entries,
the extended name_search of analytic accounts was prohibitively
slow, due to the expensive name_search on res.partner.

Restricting the search to the partner name is extremely
similar business-wise, but makes a huge difference in
terms of speed. E.g. sub-second results vs 10+ minutes
for a database with 30k analytic accounts and 600k partners.
2015-11-24 20:00:58 +01:00
Nicolas Lempereur 6fd7fc9643 [FIX] project: IE11+ issue with flex and overflow
IE11 and IE Edge presented issue in the project kanban view with content
overflowing its container.

On IE Edge it could be solved by "min-width:0" on the left part of a
kanban card, so it was an issue in the computation of widths order.

But on IE11 that wasn't enough so a less elegant fix has been used.

opw-653477

(solution found mainly by qsm)
2015-11-24 17:37:28 +01:00