- Jun 02, 2016
-
-
Olivier Dony authored
Rev. 93e9a4dc tried to speed up the 9.0 name_get() of res.partner by only calling fields_get() once for the whole name_get, instead of calling it lazily. This may have worked for name_get calls on multiple unnamed addresses (name is NULL), but this is a rare occurrence in practice - while now every single name_get() call would incur the full cost of the fields_get() call. That fields_get() call is O(n) in the number of fields, and there can be quite a few for res.partner. Calling it only for the specific 'type' field can easily be about 40x faster than without it. And since name_get() is called for each Many2One field of each record being read (due to convert_to_read()), reading a batch of records with partner fields had become quite a bit slower! Avoiding this cost entirely with lazy fields_get() calls saves quite a lot of time for the common cases. And now that fields_get() specifies a single field, it is cheap enough to be called within the loop. Non-scientific benchmark: account.invoice.search_read() in the list view of invoices took 500ms for 25 invoices _before_ this fix, and 90ms after!
-
Xudong Yang authored
Not evaluated, move the condition to the button Closes #12230
-
Jairo Llopis authored
Cannot link a method before declaring it. Closes #12057
-
Laurent Bélorgey authored
Closes #11226
-
Nicolas Martinelli authored
The field `bom_count` is added in the view for group `group_mrp_user`. Therefore when extending the view, we should make sure to restrict the access as well. opw-679172
-
Christophe Simonis authored
-
Quentin De Paoli authored
* price_average is now always positive regardless of the invoice type, because it's an average and there's no point in summing those values * price_total is now computed by using ABS() because of a migration bug of price_subtotal_signed introduced in saas-6, where in_invoice and in_refund invoices were set with a negative value while on the help tooltip it was saying that in/out refunds are negative and in/out invoices are positive. That bug was only revealed in v9 -since saas-6 wasn't using that field at all-, with the effect of having wrong values in report for migrated databases. This workaround using ABS() will be removed in a further version with a migration script to fix people's databases. * residual field is now negative for in_invoices and out_refunds. * These 2 points ensure that we can group by invoice type and sum the price_total or the residual fields to get the gross income of a month for example.
-
Christophe Simonis authored
-
Denis Ledoux authored
Since the revision bc23c92c, the inventory value of the produced items could be doubled, because the list `total_consume_moves` could contain several time the same move ids, e.g. when it was added by `total_consume_moves.append(raw_material_line.id)` and `total_consume_moves += already_consumed_lines.ids` The list is replaced by a set to ensure a same move cannot be counted twice. opw-678727
-
Martin Trigaux authored
The cron may no longer be present (e.g. deleted) and the subscribtion would be blocked in running state. Fixes #12207
-
Christophe Simonis authored
-
Jairo Llopis authored
When subscribing a user to a mailing list, the `mail.mass_mailing.contact` created is processed to identify it's name and email from the address (method `get_name_email` called in `add_to_list` and `name_create`). For a better consistency, the search of existing contacts should also be done using the method `get_name_email`. This avoids that subscribing twice `Example <example@example.com>` fails to detect duplicates and creates two subscriptions. Closes #12265
-
Raphael Collet authored
opw:678921
-
Joren Van Onder authored
Related to c6fc91b3. fp request
-
Goffin Simon authored
When computing the amount_currency, the ratio is 1.0 if the difference between amount(computed like this -sum([x.balance for x in move.line_ids])) and the amount set in the statement is not greater than the currency rounding. opw:678588
-
Olivier Dony authored
Rev. 253437f8 meant to avoid the creation of duplicate entries during translation import, caused by existing translations created with an empty `module` field. But the fix was over-zealous and caused an extra side-effect: the creation of missing translations (the blue flag icon) now creates duplicate translations if other translations exist with different `module` values. (This could happen because translations are provided by several modules, or due to manual translation entries with no module value, etc.)
-
Lorenzo Battistini authored
Equivalent of 8c337f97 but for account.move.line as well. Closes #11883
-
- Jun 01, 2016
-
-
Joren Van Onder authored
Normally when you manually add or remove money from the cashbox the reference on the bank statement line should be set to the name of the session. But because the wrong function names where used this didn't happen. Introduced by f5ad2516. Fixes #12224
-
Jeremy Kersten authored
xml template was using color name, because color index was empty. It works in English, but once translated (in french e.g.) we have background-color:noir Fix #12251
-
Joren Van Onder authored
We allow users to specify QWeb in the header and footer fields of the receipt. Because the browser receipt and the ESC/POS receipt use a different format (HTML and ESC/POS XML respectively) we don't render this QWeb to both receipts. Currently it is only rendered for the ESC/POS receipt. When this is the case however, we shouldn't display the unrendered QWeb on the regular browser receipt. This commit simply hides it. Perhaps in the future we can provide an additional parameter in the <DOCTYPE declaration that allows the user to specify whether he wants the QWeb to apply to the HTML receipt and/or the ESC/POS receipt. opw-678170
-
Richard deMeester authored
Change tax collection definion for private use (and others) to not accumulate in GST accounts. opw-678956 Closes #12081
-
Richard deMeester authored
Added new accounts, fiscal positions and taxes opw-678956 Closes #12081
-
Richard deMeester authored
Chart of accounts structure and localisation for New Zealand. opw-678956 Closes #9234
-
Odoo Translation Bot authored
-
- May 31, 2016
-
-
Denis Ledoux authored
If `probability` is not being written, `vals.get('probability')` is `None` `None` < 100 is `True` While it should not remove the `date_closed` value when the probability field is not being rewritten on the lead, but something else is. opw-677273
-
Olivier Dony authored
Related to #12066 (see comments)
-
Jeremy Kersten authored
Revert and related to commit: odoo/odoo@d1073f8e483ea0afc029091e62e2b3aa6aac5145 Re close #12246
-
Quentin De Paoli authored
-
Jeremy Kersten authored
In v9, stages are not shared by default. So when you create a new job position, you need to specify manually which stages are available for this job position. But the field stage_ids was not available.
-
Sylvain LE GAL authored
onchange_picking_type func now return picking_type_code The stock.picking has an attrs to hide the partner_id for internal transfers. It was not set as picking_type_code was not set. Closes #12117
-
Sylvain LE GAL authored
Closes #12117
-
Goffin Simon authored
It is not possible to group by "Expected Date" because the field is not stored. opw:678591
-
Goffin Simon authored
The entries created from an asset don't have to be posted if the asset category has its field "open_asset" set to False. opw:678771
-
Goffin Simon authored
When creating an invoice line from a PO, if the product is linked to an Asset type then the account used for this line must be the expense account. When creating an invoice line from a SO, if the product is linked to an deferred revenue type then the account used for this line must be the income account.
-
Wolfgang Taferner authored
`all([]) = True`, therefore if there is no `matched_debit_ids` or `matched_credit_ids` on a payment ==> boom when you access `payment.matched_debit_ids[0]` opw-677157 Closes #12232 Closes #12242
-
Jeremy Kersten authored
Odoo serves files based on the mimetype imported with python module Mimetype. In some case, mimetype on windows for svg is undefined or misconfigured and the svg is returned as text/plain (and so xml and not img). This commit overrides the default mimetype to render .svg file with mimetype 'image/svg+xml'. It is similar to add/override the key from windows registry with: ``` [HKEY_CLASSES_ROOT\.svg] @="svgfile" "Content Type"="image/svg+xml" ``` The advantage to override it in Odoo, is to be sure that even if this key has been updated or deleted by a cleaner software or malware, Odoo continue to work This closes odoo/odoo#12150, closes odoo/odoo#9061, closes odoo/odoo#9118
-
- May 30, 2016
-
-
Joren Van Onder authored
When a user goes through the trouble of manually modifying the depreciation lines he will lose all his work when clicking on 'reset to draft'. Furthermore, if he then goes through the trouble of repairing the problem by once again manually changing the depreciation lines he will again lose his work when pressing confirm. opw-678678
-
Goffin Simon authored
Used case: Create a SO with invoicing policy based on delivery. Don't deliver anything and Create invoice for all invoiceable lines. Result: There was no invoice created and no warning message. After the fix: A warning message is raised when after clicking "Create invoice",for any reason it doesn't create an invoice. opw:678567
-
Ronald Portier authored
The field generation is most of the time following the pattern `field_<table name>_<field name>` but in case of name clash (e.g. res.partner.category - id and res.partner - category_id), the id of ir.model.field is added at the end of the external id during the field creation. The more flexible way to link to an ir.model.field is to use the syntax `search=[('model', '=', <model>), ('name', '=', <field name>)]` to avoid errors as in #12192 when the "first" external id no longer exists. Fixes #12192 Closes #12198
-
Goffin Simon authored
The sentence concerning the adviser should not be raised if the user is an adviser role. opw:678458
-