In case of a partial delivery of the products to receive, the procurement is
not considered as done since procurement.purchase_line_id.order_id.shipped is
false.
opw-641503
amount_line_tax must be used to compute the _amount_all. In this way,
the taxes are computed by "compute_all" which takes into account how
to round(globally or per line). Inspired from "sale.order" behaviour.
Fixes#6765
opw:640211
The delivery must be updated when the cart is updated.
The method "_check_carrier_quotation" called by "_cart_update" deletes sale order line related to delivery.
Then each line passed to "_cart_update" must be checked with "exists" to be sure that the record is not
missing.
Related to the task : 12239
opw:641913
Basically, computation of the `inventory_value` is now done
in batch instead of one by one.
In a real use case, the computation of the stock valuation
passed from 20+ minutes to less than a minute.
This revision contains an unusual SQL request:
`SELECT DISTINCT ON`
Basically, it returns the most recent line of table
product_price_history for each tuple
`(product_template_id, company_id)`
which is actually what we want, with good performances.
See postgresql doc for more information:
http://www.postgresql.org/docs/9.0/static/sql-select.html#SQL-DISTINCT
opw-641154
The Taxes report gives the possibility to choose a chart of tax.
This chart of tax wasn't respected when printing the report,
all taxes from all chart of taxes of the company were printed.
opw-642362
In css, overflow-x and overflow-y must have the same value. If overflow-x is equal to
auto then overflow-y is equal to auto.
To solve the problem, the height of the input is removed because it is forced by the Jquery
auto-completion plugin according to the wrapper.
Without this patch, when you go to Settings > Import/Export > Export Translation and click on the arrow to
to show the list of modules you can export, the list is partially hidden.
opw:632607
The commit 3269ad8f get back the behaviour of 7.0 (which changed in
october 2014) that when a field is overrided via the old api, attributes
of a previous definition of the field are lost.
This fix corrects the case when this behaviour might have had an effect
so specified attributes overrided don't get lost.
related to opw-639712
When the uom(Unit) set by default is not in the same category than the uom category of the product,
the uom of the product is set.
When the uom is changed, the theoretical quantity and the real quantity are recomputed.
opw:641027
When a product is scrapped, we set the reservation_id of the scrapped move on
the quant corresponding to the original move (e.g., the move which brought a
manufactured product from production to stock). By doing so, we will subtract
the quantity to scrap from the appropriate quant.
opw-641852
When filling the form (for invoice or delivery details), once a field has been
filled, it's no longer possible to remove the value of this field.
e.g. set a company, not possible to remove it when modifies the address
This is due to the `get(key)` call that is considered as False with empty
strings. Instead, check the existance of the key.
Still not accepting mandatory in the form (not checked in this method).
Fixes#7017
If an event exists on Google but was not synced yet in Odoo, the synchronisation
would fail.
When self.OE.found is False, self.OE.event is not defined and trying to access
it would fail (it's a python object, not a recordset)
Check the ownership after making sure the event is present in Odoo.
Fixes#7034
When a logged call is created from the tree view, the mobile phone of the
partner is not filled in automatically, while it is in the form view.
opw-640549
When a user tries to log into a postgresql database with no view web.login (this
happens if the database is not an odoo database or using a previous version of
odoo), the rendering failed, producing a 500 error (with no detail for the user)
Instead, redirect to the database selector with an informative message.
Fixes#3443
The database selector page is a jinja template with no access to database
required so should be able to be displayed on any database.
Future improvement could verify the version of base module for even more precise
verification before login (but need to make sure it's always accurate).
When a sale order has in state != draft, we raise a error message since commit
f6c65a3d9e.
But if we don't reset the sale order id from the session, the user cannot
continue to navigate on website because the user will have the error each time.
If the state of the PO is 'approved', there is no transition foreseen in
order to cancel the PO.
The user might be blocked in the following situation:
- Create a purchase order with invoicing set as Based on incoming shipment
- Validate the purchase order, create the shipment
- Then, cancel it (the shipment)
- Return back in the purchase order, the PO should be in shipping exception
- Hit the "manually corrected"
- Then, try to cancel the PO: nothing happens.
opw-641014
Canceled lines must be excluded from most of the operations done on a purchases orders.
The check has been done in some places but some of the loops on the order lines do not do it.
This commit correct them.
having lines with products using a different UOM for
sales and purchases
If a product does have a (different) purchase uom, we should first
take it as a base for calculating prices as the standard price relates
to it and not the sale (normal) uom.
Closes#6829
opw-640616
For emails sent via Office 365, reply-to header could contains additional spaces
or get multiline header.
e.g.:
In-Reply-To:
<4ba8f246904b4fedb49fbab7945a7f82@AM3PR06MB433.eurprd06.prod.outl$$k.com>
The message lookup fails if header is not stripped
The product view forces the decimal accuracy to 3 digits on weight and
weight_net, but the accuracy can actually be set using the 'Decimal Acuracy'
feature so it must not be forced here.
If User A created an event In Odoo, inviting User B,
Then, if User A sync his calendar with Google,
user B have an invitation to this event in Google,
if user B refuses the event AND remove it from his Google calendar
and then syncs his calendar to Odoo,
the event was removed from the Odoo calendar, of all attendees.
opw-641356
With User A <a@gmail.com> and user B <b@gmail.com> both syncing
their calendar with Google.
If User a created an event X, adding as attendee himself and user B,
and then synced his calendar to Google, a new event was
created in User B Google Agenda automatically, representing the
invitation.
At this stage, X appears only once, in the four calendars
(Odoo cal for A, Odoo cal for B, Google Cal for A, Google Cal for B)
If user B then synced his calendar to Odoo, the event X was
duplicated in three of the calendars (Odoo cal for A and B, Google cal for B)
If then user A synced again his calendar with Google, the event X
was duplicated in the four calendars.
From then, a duplicate loop began, at each sync of the both user calendars.
opw-639419
Method refund_sheet relies on the fact that on 7.0, copy=True was the default
behavior for one2many fields.
Bonus: remove the call to compute_sheet since that what is done by
self.signal_workflow(cr, uid, [id_copy], 'hr_verify_sheet')
opw-640348
When we change a product line of an account invoice, a current unit with
a invalid unit category was not dropped which should be since:
- it is different from a sale.order,,
- there is a domain on the unit of measure only allowing units from the product's unit category.
This fixes drop the current unit of mesure in this case.
opw-640985
When an ir.attachment is created from the ir.action.window "Resumes and Letters"
then the res.model must be set by default with 'hr.applicant'.
opw:641070