Removed overridden unlink() of account.invoice/(.line) models by introducing ondelete='cascade'
for 'account_invoice_line' field for 'membership.membership_line' model
- Split compute function in res.partner into 4 functions as they no more share the same dependencies
- removed dead constraint from 'membership.membership_line' model. That constraint checks if the invoice's date
is greater than membership line's date but the membership line is created before the draft invoice is created
(and that too without date set), hence it can't be raised.(Though, it can be raised if we check it on 'state' field).
I assume this was necessary before the migration of payment because
an api.one wrapper was added by the auto-guess api feature.
Since payment has been migrated, this decorator is no longer present
and the result of _registration_render is no longer encapsulated in
a list. Therefore, taking the zeroth element was akin to taking only
the first character of the rendered html. Usually \n, which is not
useful but which also prevented the crash to be easily visible.
* mail_message.message_read() method is not used anymore since the chatter
refactoring in v9. message_format() is used instead. Tests for this method
are also removed, as they have no use anymore.
* mail_thread.message_set_read() is not used anymore. set_message_done is the
only method used by the new chatter as there is no read state anymore.
* removed an unused parameter in set_message_done, by the way
* product.category: remove complete_name field as display_name can be used
where the field was used
* product.supplierinfo: remove computed qty field. This field originally
contained the min_qty computed into the product_uom. However commit
3c186c5807 broke that field without reason.
Since 2011 no one complained about this field being unnecessary, so let us
remove it.
* product.template: shorter and less spaghetti version of create_variant
method
* product_product._sellect_seller: fix use of default parameter in method
kwargs + use odoo standard datetime default value
A new API is introduced for price computing using pricelists. It is simplier
to use in most use cases, which is computing the product price in a given
pricelist. Old methods return dictionnaries and tuples, which are rarely
used in the code.
product_uom._compute_quantity is an ensure one multi method taking a browse
record as second paramter. It replaces _compute_qty and _compute_qty_obj
to have a single and standard computation method.