The behavior of the datetime widget was to focus in the field every time a date
is chosen. This causes an issue if the datetime widget is called from an
editable list. Indeed, the list editable will consider that the value has been
set, and therefore the value will not be changed anymore if the user choses
another date.
The new behavior is to put the focus only when the date picker is hidden,
therefore the editable list will consider the value set only when the selection
is done.
opw-644062
Fixes#7463
When we go from one field to another via the tab key, in the form view what happens is:
{{we get a blur from the current field}}
-> if [[widget was not in state clicked (which can be gotten for example by clicking on a focused field)]]
-> blur event is cancelled,
-> the blur event is set to be triggered soon
-> the clicked state is set to false
{{we may get a focus for the next field}}
-> if [next field get an onfocus event]
-> blur event is cancelled,
So if :
- the state is not clicked and,
- the next field don't get an focus event.
We get a blur event which will either save (if a field value has been changed) or cancel
the form view editing and will hide the current edition, hence losing the focus.
For example, it happens on a readonly fields with field containing an `<a />` tag, on
some browser (for example google chrome), the focus event will not get triggered (it still
work if we were in a clicked state) so we can't cycle thought a list editable cells if there is a readonly field in it.
closes#7446
opw-643718
The product_id_change method of sale.order.line
ignored the passed context.
The context was simply overwritten,
which is no a good practice.
Besides, it prevents customizations.
Closes#7447
opw-643983
Use the lang from the sale order's partner when updating suggested
product line. To achieve this, the onchange has been replaced by an
onchange of the new api which gives access to all the fields.
closes#7268
opw-643098
This reverts commit 2f5d681135.
The previous commit was intended to fix a wrong assumption in case the
purchase uom was different to the standard uom.
The wrong assumption:
- price is related to purchase uom
- therefore it was tried to convert the bom price accordingly
- as the price needs to be already in standard uom it does lead to a
wrong calculation now
Closes#7421
To determine the account.move.line to reconcile, first it tries to match with
the ref and the amount of the account.bank.statement.line and if it doesn't match,
it just tries to match with the amount.
opw:643867
If copy=True for production_id, a move created from a push rule will be added
in the list of Product Produced. Therefore, we must set manually the value of
production_id of the scrapped moves.
opw-643877
Besides, the test was particularly useful:
It tested that when 'Buyer' was sent as firstname
and 'Nobert' as lastname to Authorize,
authorize returned the opposite, 'Norbert' as firstname
and 'Buyer' as last name.
In the partner model, there is only one field `name`.
The first name and the last name are not within two
separated fields.
By assumption, the firstname is written before the last name
(first <> last)
This assumption should be kept when sending the
first name / last name of the partner to the payment acquirers
e.g. Paypal.
opw-643120
Ship in 2 steps:
The Packing zone location is inactive but it is used by default as destination
location (instead of Output) in the Pick operation.
opw-643734
When you apply payment in POS,
it takes current time for "date" field
on bank statement line,
but should use context_timestamp to take care
of user timezone adjustments.
Example:
If user is in time zone GMT-6:00,
then after 6:00pm all bank statement lines will be recorded
with date of next day, and all closing reports and related
accounting will be wrong!
Fixes#2199Closes#2200
When a landed costs is applied on goods that are already out, these landed
costs need to be subtracted in the stock valuation account and added in the output account.
(they were just added before)
When the landed cost is negative, it needs to do the opposite for what is already out also.
When the public user comments the website, he will be redirected
to the login page and his comment will be posted with his logged
user name.
opw:643412
This is related to rev. 55b7f15ee2
Prevent crash when there is no line to display
in the stock valuation report
Reporting > Warehouse > Stock Valuation.
Like when there is not yet any data, or the filter gives no result
opw-643748
While working on project task it is possible
to record "task work" that will automatically
create timesheet lines. These are not by default
included into any timesheet, but they need to
appear in reporting nonetheless.
These lines disappeared from the analysis view
after the performance improvement of
rev. fe31451899
which introduced a JOIN with the `totals`
CTE table - and should have been LEFT JOIN.
When printing these reports from the accounts list
Accounting > Configuration > Accounts > Print menu > General Ledger
the ID of the wizard was considered as the ID of an account,
leading to obvious issues when this ID wasn't available
in the account_account table, or when the user
do not had the access rights to see the accounts with this
ID.
The override was completely useless: The wizard is
launched whether you print these reports from
Accounting > Reporting > Legal reports > Accounting Reports
or from the accounts list, and the super _get_account can
be called correctly for these two use cases.
opw-643589
The precision of the field 'hours' in project.task.work and the precision of
'remaining_hours' are not the same. This is why the difference between them can
generate some very small negative difference which implies an infinite percentage for
the working progress time.
opw:643649
This revision is related to 279f225cf0.
`_get_pickings` is used as trigger store method
for several computation fields.
The trigger restriction applied in the above commit should
only be applied on the `min_date`, `max_date` and
`priority` fields.
This rev. is related to 279f225cf0.
The `product_qty` computation priority should be
important, as other compute fields depends on it
such as `weight` and `weight_net` from the
delivery module
This is a performance revision.
Some stored functions field were recomputed uselessly.
In mrp, `hour_total` and `cycle_total` were recomputed
at each write on `mrp.production`, while they should be recomputed
only when there is a change on the `workcenter_lines` field,
or when there is a change in the `hour` or `cycle` field
of these `workcenter_lines`.
In stock, `min_date`, `max_date` and `priority` of
`stock.picking` were recomputed each time a new move
was added to the picking,
wether or not the 'expected_date' of this move
was between the `stock.picking` `min_date` and `max_date`,
and the priority not greater.
In stock, `product_qty` of `stock.move` was recomputed
at each write on the `stock.move`, while it should be
recomputed only when there is a change in `product_id`,
`product_uom` or `product_uom_qty`, as the computation
method only depends on these three fields.
In stock_account, the `invoice_state` of `stock.picking`
was recomputed each time a new `stock.move` was associated
to the picking, wether or not the `invoice_state` of the move
was already the same than the `invoice_state` of the picking.
opw-643560
This fixes 2 issues.
First, it keeps consistent the precision required for posted entries and the
precision for the balance assertion. This could be an issue if the account
precision is larger than 4.
Then, it makes sure to round the amount with the appropriate precision to avoid
numerical errors. For example 1.2344 - 1.2345 = -9.999999999998899e-05, which
is indeed smaller than the required precision 10 ** -4.
A minimum precision of 10 ** -5 is kept for historical reason.
Fixes#7276
opw-643305