Commit Graph

83357 Commits

Author SHA1 Message Date
Denis Ledoux 2c3c2b57db [MERGE] forward port of branch 7.0 up to f2f4391 2015-04-30 10:50:51 +02:00
Denis Ledoux f2f4391e8b [FIX] account_followup: partial overdue payments
This is related to rev. ab9f02cdee

The above rev. take care to exclude payments that are not yet due;
meaning the ones due in the future, by checking the maturity
date.

Problem: Payments (e.g. move lines from bank statements)
do not have a maturity date. Only move lines that actually
have a maturity date, in the future, must be excluded,
not the one that do not have a maturity date.

opw-633930
2015-04-29 17:45:02 +02:00
Nicolas Martinelli fa01054ae0 [FIX] delivery: delivery price uses pricelist currency instead of company currency
opw-632574
2015-04-29 17:17:20 +02:00
Mohammad Alhashash a6a3db3188 [FIX] account: custom '_where_calc' method instead of 'search'
The domain on account.account was preprocessed in search method but it had no
effect on read_group. This lead to inconsistency or errors when using 'goup by'
filter.

Move domain processing in '_where_calc' method instead as this is used by both
'search' and 'read_group'.
2015-04-29 11:17:47 +02:00
Mohammad Alhashash 717a695317 Revert "[FIX] account: remove journal_id from account domains"
This reverts commit 24526b18a7.
The journal_id field is not present on account.account but is processed in
search method.
Next commit will improve the processing to also accept journal_id in read_group.
2015-04-29 11:06:29 +02:00
Mohammad Alhashash 24526b18a7 [FIX] account: remove journal_id from account domains
From invoice lines and move lines views.

The model 'account.account' has no field journal_id.
2015-04-28 16:34:29 +02:00
Denis Ledoux 39325842e4 [FIX] note: do not set self in args of a super call
This silly mistake prevents to group notes by
something else than stages.

opw-633980
2015-04-28 11:18:07 +02:00
Goffin Simon 3c055a769f [FIX] account: Taxes report
The Tax Report printed with details should not include draft accounting entries.
Technicaly, the account move lines include in a draft account move do not have to be
printed

opw:633642
2015-04-27 16:25:43 +02:00
Denis Ledoux 09b277c008 [FIX] crm: fp mistakes during d6ae7fb7db.
`crm.meeting`
has been replaced by
`calendar.event`

`base_calendar.view_crm_meeting_search`
has been replaced by
`calendar.view_calendar_event_search`
2015-04-27 13:21:51 +02:00
Denis Ledoux 70d28a69b9 [FIX] crm: silly mistake during forward-port d6ae7fb7db
type="object" was already there, no need to set it twice.
2015-04-27 12:46:01 +02:00
Denis Ledoux d6ae7fb7db [MERGE] forward port of branch 7.0 up to 3e7d3c7 2015-04-27 12:19:43 +02:00
Denis Ledoux 3e7d3c7ee4 [FIX] account: tax_amount can be null in database
The `tax_amount` of move lines is by default set to `0.0`.
Nevertheless, this default value is set by Odoo,
not by postgresql.

This is therefore likely that the `tax_amount` is set as
null instead of 0.0, in database.

Therefore, when getting this value directly with a SQL
request, this is possible that `null` will be returned.

Therefore, in this specific case, `res.get(record.id, 0.0`
could return `False`, if the sum of `tax_amount` is `null`,
and try to multiply a boolean with an integer is not possible:
`_rec_get(rec) * rec.sign`

opw-633903
2015-04-27 12:01:21 +02:00
Thomas Rehn e8ffc09b30 [FIX] ir.ui.view (diagram): do not depend on semi-random order of _columns
The ir.ui.view.graph_get() method depended on the natural
semi-random order of Python dict keys in the _columns dict.

When the number and/or names of the _columns happened to
yield the o2m field of the "incoming transitions" *before*
the "outgoing transitions" of the "Node model"
(e.g. workflow activity), it would swap the incoming and
outgoing transitions fields around, causing a crash later
in the `tools.graph.process` method (currently an infinite
loop in the `tree_order()` method of tools.graph.py).

Closes #3614
Fixes https://bugs.launchpad.net/openobject-server/+bug/1316948
opw-633765
2015-04-24 13:50:26 +02:00
Martin Trigaux 641c25b2e6 [FIX] project: typo 2015-04-24 11:19:34 +02:00
Josse Colpaert 6dcccae568 [FIX] project: use selected unit of measure in gantt display
Hack to use working time unit in gantt view. Similar to 533399f for project.task
Fixes lp:1108913, opw 613979
2015-04-24 10:53:54 +02:00
Martin Trigaux 316be12a3c [FIX] purchase: mark order as invoiced when fully invoiced only
Make sure the purchase order is marked as invoiced only when fully invoiced.
If the invoices are generated on delivery order (invoice_method picking), make
sure all products are delivered before setting it as invoiced.
opw 614256
2015-04-24 10:46:42 +02:00
Nicolas Lempereur 81a3f56651 [FIX] stock,event,pos: fix "today" filter with regard to timezones
The previous filters didn't take timezones into account, and
returned stringified naive datetime values in local browser
time. Those would then be interpreted by the server-side as
UTC date, and depending on the current timezone offset vs UTC,
yield partially incorrect results.

By returning directly a datetime.datetime object instead of
a stringified version (see previous commit 76881fb),
we can get the expected result regarless of the timezone.

Fixes #2972
Closes #6229

opw-621282
2015-04-23 14:11:24 +02:00
Nicolas Lempereur 76881fb226 [FIX] web: backport datetime.toJSON() so we can return local datetimes in search domains
This fix adds the toJSON() method to datetime.datetime,
so domain expressions can use datetime values directly,
without having to compute the stringified version
with convoluted strftime() and timezone calculations.

The datetime results are sent down to the JSON-RPC
level where the JSON.stringify() serialization will
convert them to UTC string, to be deserialized
properly as UTC datetime values on the server side.

Thanks to this we can use the browser's local midnight
timestamp in a filter expression, for example like this:

`datetime.datetime.combine(context_today(), datetime.time(0,0,0))`

and get the expected result regardless of the user/browser's
timezone.

related to issue #2972 and pull request #2914 and #6229

(Next commit will fix them)

opw-621282
2015-04-23 14:05:56 +02:00
Martin Trigaux 5267e3a158 [FIX] portal: share with group wizard
Correctly creates menu and add implied groups.
Since the conversion from res.portal to res.group, we lost the field
parent_menu_id so a search is needed to find parent menu.
To add the access of existing users to the new groups, implied id rules are
needed. opw 612594
2015-04-23 13:53:08 +02:00
Martin Trigaux ab65c388cd [FIX] crm: list of meetings from opportunity
When opening the list of meetings from an opportunity, show only the meetings
linked to the current opportunity.
Use search_default_ to be able to remove the filter if not needed.
Remove context on meeting button as it's ignored in action_makeMeeting (and
there is no field attendee_id linked to a crm.lead anyway)
opw 614039
2015-04-23 10:00:01 +02:00
dhr-odoo cb5f00f580 [FIX] orm: ordering on >1000 records
When reading over IN_MAX (currently 1000) records, the select is slip into
subsets of IN_MAX records. However the list of ids was split using set() method
which removes order that may have been pass. The subsets are ordered using
_order attribute but the subsets were not ordered between themself.
This is an issue in case of browsing a o2m field with more than 1000 lines as it
will return sorted blocked but the order of the blocks is the order of the
contained ids (e.g. split(2, [5, 4, 3, 2, 1]) -> [[2,1], [4,3], [5]]).

Removes the set() to make sure the order of the given ids is preserved.
opw 616070, linked to #439
2015-04-22 12:14:33 +02:00
Rifakat Haradwala ecdaf89469 [FIX] membership: shown customer invoice form instead of supplier
When somebody buys a membership, he is a customer, opw 615986
2015-04-22 09:10:28 +02:00
Vincent Vinet 3cc3ab6252 [FIX] document: polynomial time reordering of document ids
Triggered every time on list views as the list view uses a
search_count (filtered but unlimited) to display pagination.

closes #6397
2015-04-21 09:49:47 +02:00
David Monjoie f4e1974d67 [FIX] web_calendar: fixed counting of days when selection spans multiple weeks
As event_obj._length doesn't return the number of days when the selection spans
multiple weeks, the test was wrong when the selection ended on the first day of
a subsequent week.

This fix was originaly written by rha-odoo at 95d344b, but I rewrote it a little.
I would have liked a cleaner way of finding how many days there were between the
two dates, but I couldn't find anything better, considering I didn't want to
create new objects just for that test.
Fixes opw 614703.
2015-04-21 09:37:50 +02:00
Martin Trigaux 0b2bc27adc [FIX] stock: use unit of measure for manual receptions
When using the manual reception wizard, if a quantity in a different unit of
measure was set, the unit was ignored. opw 617336
2015-04-20 17:16:22 +02:00
dhr-odoo 056ab55b6b [FIX] Passed bank statement's currency in payment_rate_currency_id of the account.voucher when importing payment lines 2015-04-20 14:28:07 +02:00
Christophe Simonis 9323f2b4c7 [MERGE] forward port of branch 7.0 up to a091de8 2015-04-20 12:10:48 +02:00
Christophe Simonis a091de8d8d [FIX] core: no traceback when closing socket.
Closes 5057
2015-04-20 11:54:58 +02:00
Martin Trigaux a939efdb3f [MERGE] forward port of branch 7.0 up to 21d3be8 2015-04-17 14:23:21 +02:00
Alejandro Santana 21d3be87b3 [FIX] tools: image size as power of 2
Backport of 6a8f395
Fixes #5677
2015-04-17 14:17:19 +02:00
Christophe Simonis 50665b499a [MERGE] forward port of branch 7.0 up to d0ef1b9 2015-04-16 19:13:56 +02:00
dhr-odoo d0ef1b938d [FIX] Fixed wrong digits format issue for float fields when thousand separator is '.'
The function was returning the number value directly before proceeding to any formatting.
2015-04-16 15:30:20 +02:00
David Monjoie cd94f10e1d [FIX] base: fixed display of address in IE11
Spiritual backport of 5de677208c
which should have been fixed in 7.0 back then.
2015-04-16 14:27:12 +02:00
Martin Trigaux 884864c40f [FIX] account: do not show empty partners in manual reconciliation
When doing a manual reconciliation, the current filter could restrict the
visibility of move lines and show empty results for some partners (e.g. filter
the lists on only one partner will show empty list of moves for other partners).
This is also the case for multicompany restrictions.
Integrate the current filter to the search to only get results for displayed
lines.
Fixes #3817, opw 618134
Fixes #5221, opw 632095
2015-04-15 17:10:01 +02:00
Denis Ledoux 5fb717a971 [FIX] account: display name field in supplier refunds
The name field contains the refund reason.
The reason is filled when you create the refund
from the refund wizard available when
pressing "Ask Refund" on a supplier invoice.

As this field wasn't visibile on the supplier
invoice form, this wasn't possible to change
the reason on draft supplier refunds after
having created them through the wizard, while
you could change your mind or having done a
silly mistake in the wizard, that you could
edit since the invoice is stil draft.

This was also not possible to set a reason
when creating the refunds without going through
by the wizard.

This was also not possible to change the reason
when you duplicated your supplier refunds.

opw-632756
closes #6301
2015-04-15 17:00:25 +02:00
Denis Ledoux 51774f2a45 [FIX] mrp_repair: missiing taxes field in invoicing tab.
Taxes can be applied on the repair fees.
The field was defined in the model, it was just missing
in the view.

In addition, the product_id_change worked already for the
taxes.

opw-632898
2015-04-15 16:02:35 +02:00
rmu-odoo 3f7d168130 [FIX] sotck: correctly set reference on internal move
When creating a chained picking, the first move has no sequence, this is because
there is no sequence for stock.picking.internal.
Set the sequence before the chained move so that the sequences are in the right
order. opw 621261
2015-04-15 15:23:26 +02:00
Christophe Simonis 2ffbb5f93d [MERGE] forward port of branch 7.0 up to d246e36 2015-04-14 11:40:23 +02:00
Nicolas Martinelli d246e36c82 Revert commit "[FIX] sale_margin: purchase price calculated using the currency of the price type"
Reasons:
- the currency conversion is done assuming that the cost price currency is the company currency
- we support only one price type per field. Defining several price types on the same field using
  different price types is not supported.
2015-04-13 19:09:20 +02:00
Christophe Combelles 737728a7a0 [FIX] base: import po file with comments only
Do not crash when importing a po file with only comments lines (e.g.
autogenerated files)
Fixes #4887
2015-04-13 11:38:42 +02:00
Christophe Simonis d3e7a8ef5e [MERGE] forward port of branch 7.0 up to 856bc6f 2015-04-10 18:24:46 +02:00
Olivier Dony 856bc6f2b1 [FIX] apply same visibility rules as base 2015-04-10 17:15:50 +02:00
Somesh Khare 39010d3856 [FIX] account: wrong amount for tax included
Backport of 8.0 code, rev f61339b
Create a new journal item with an tax included, the automatically created tax
line had the amount computed as tax excluded.
Fixes #3731, opw 618305
2015-04-10 12:17:52 +02:00
Rucha Dave 2a3ce719bc [FIX] delivery: do not use canceled lines in weight computation
Canceling a line on a delivery order was not updating the weight of the package.
opw 618532
2015-04-09 14:45:38 +02:00
J Bradshaw ee57fbb022 [FIX] README: Fix URL and spelling
Closes #6049
opw-632480
2015-04-09 14:26:37 +02:00
Akash Balar 4ba72fbacb [FIX] stock: reset date_done field at duplication
As the state is reset to draft, makes no sense to keep date of completion.
2015-04-09 14:12:51 +02:00
Denis Ledoux 0b684b950f [FIX] mrp_operations: missing params in overriding methods
The context wasn't defined in the below methods:
- action_production_end
- action_in_production

while it is defined in the base methods, in the mrp module.
This doesn't lead to any issue in standard
modules, but it prevents to correctly
override these methods within custom modules
when mrp_operations is installed.

opw-632425
2015-04-09 10:22:30 +02:00
Nicolas Martinelli 7b7b0d148a [FIX] sale_margin: purchase price calculated using the currency of the price type
When the margin is calculated, the purchase price is calculated using the currency of the price
type 'standard_price' instead of the currency of the company, since they can be different.
opw: 631884
2015-04-09 08:20:36 +02:00
Somesh Khare c09095cbc9 [FiX] sale(_stock): missing state on report
The state 'Quotation Sent' was not visible on the sales analysis report (e.g.
group by Status). Add the missing state to the report to correctly disaply it.
opw 619748
2015-04-08 16:36:04 +02:00
Olivier Dony 56c95d2843 [FIX] report_sxw: setLang() should discard browse_record cache
`setLang` alters the "browse" context of the documents
being printed, but it must also discard any values
already cached, as they could be using a different language.
This is the case when the report uses translatable fields
on `res.partner`, because `setLang` is usually called
with the target partner language, hence prefetching
the translatable fields with the user's language instead
of the partner's language.

E.g. `setLang(o.partner_id.lang)` will cache any
translatable field on `o.partner_id` in the language of
the *user*, not the *partner*.
2015-04-07 18:33:49 +02:00