When displaying a field, it is usually preferable to use the 't-field' qweb tag
to avoid access problems: the name_get is automatic so you don't need to access
the model sub-field (in this case, you don't need to access the res.partner name)
The new `summernote in iframe` version of the
FieldTextHtml widget is not ready for prime time
yet.
Usability is not very good when used as a replacement
for the previous html editor, especially in email
composer windows, and initial loading is very slow.
For now we only enable it as FieldTextHtmlFrame for
mass_mailing templates, where isolation of the
style is important (so that recipients receive the
exact same result as was displayed on screen, without
side-effects caused by backend/frontend style)
In master the summernote version will be improved
and the old CLE version will be dropped completely.
Broken in 82fee7dfe8 porting of quick create to Bootstrap modals: in
case quick_create is disabled, the creation of the quick_create dialog
is bypassed and so is defining this.$input, but focus() calls still
happen and blow up.
Create a dummy $input in the constructor so it's alway possible to call
this.$input.focus().
The UoM of a product can be changed to whatever UoM if there have not been made any done stock moves.
If there are, you can not change the UoM. If there are not done moves, you can not change the category
anymore as the conversion of the product_qty will give an error.
The reason we put the constraint is that we would need to change all the qty values of the quants
when we change UoM. It is better to avoid this (e.g. rounding). That is why we put the constraint.
There is no reason to restrict change of uom_po_id, except that it should
fall within the same category as the UoM. (constraint)
In Messaging, default filters were never loaded because the action
wasn't given as argument to the searchview initialization. The action is
required for the filters to be loaded since rev. 5cd78b891b.
The option 'add to spreadsheet' works under the hypothesis that the
current action is a ViewManager. It crashes in other contexts (e.g. in
Messaging, mail box), as it tries to retrieve the list_view id of the
ViewManager.
We now only add the option in the Favorite menu if the current action is
a ViewManager.
first, I want to say that I'm not proud of this. Let's just say that it
is better than the previous code (of which I'm not proud either).
The issue is that the sub menus (filters/groupbys/favorites) aren't very
good when their height is too big, and they're hidden below the screen
without scrollbar. Previous code tried clumsily to compute the correct
max height in js, but it was only done in filters menu, and did not
always work. This code do the same in css. This would be good except
that it is just an estimation: calc(100vh - 125px). It assumes that
the header will approximately take 120px, and size the max-height
accordingly.
The domain on the partner field in the bank statement lines
was too restrictive: You should be able to select partners
that aren't either customer or suppliers. For instance, your
employees.
opw-630017
The signature and behavior of function template() of underscore.js has
been changed from rev. 1.7.0. It doesn't accept an initial data object
anymore, and always returns a function.
This commits adapts our calls to _.template(). This fixes display bugs in
list views (e.g. the progressbar which was not displayed).
This patch removes the asynchronous code that was
still used to open the autocompletion drawer.
Even with the setTimeout delay forced to 0, the
asynchronous handling meant the final ENTER
keyUp event could be processed before the opening
of the autocompletion drawer related to the last
key pressed. This would trigger the search with
the search string of the previous autocompletion
popup, missing the last few keys.
Also handle ENTER at keyDown, because in some
rare cases a barcode scanner may emit only
the keyDown event for ENTER, without the
corresponding keyUp, causing a merge of two
successive scanned barcodes.
Based on many tests conducted with different
barcode scanners, the only thing that
is guaranteed is the correct order of the keyPress
events for all regular characters, and the
fact that the ENTER keyDown and/or keyUp will
always be sent after them.
All other events can be mixed or simply missing
if you make a rapid succession of scans, especially
if done with a long series of barcodes.
Scanners tested (with 1ms data transmission delay):
- Honeywell Eclipse MS5145
- Dacomex Slim 50mm CCD scanner
ORM will show lines in production.move_lines even if done (which the domain should avoid)
when processing the production (as they are probably still in cache). We explicitly skip those lines.
When producing more with lots in consumed and produced, we added the consumed_for link as
the lot tracking requires to have this link between the consumed and produced moves.
The extra move of the produced goods should also be confirmed and not created as confirmed immediately.
That way it can still apply the push rules. (Gabriel Demmerle)
Table borders remained the same color as in the "light" half, an overly
bright gray (#ddd) on a very dark background rather than a very light
gray on a white background.
Convert to a shade of dark gray lighter than the background, but nowhere
near as light as the text itself.
* when users press ENTER after editing some custom search, the resulting
filter is now applied.
* when users press ENTER in favorite menu, save current search, the
current search is now saved
if the graph view is set in bar mode, and does not have any groupby,
then it tried to read some property from its viewmanager, which results
in a crash. It is most likely the remnants of the old code, this commit
correctly sets the string to the current measure.
The test for account followup use UTC time, but the default `date_maturity`
and `date_due` of an account invoice come from fields.Date.context_today`.
One failing test for project_timesheet also used `today` instead of
`context_today`.
So depending on the test user timezone, an error of one day (if UTC time
and user time are on different day) occured which failed the tests.
For example:
* user has GMT+1 timezone, test fails 0:00am–1:00am (11:00pm-0:00am in UTC)
* user has GMT+3 timezone, test fails 0:00am–3:00am (9:00pm-0:00am in UTC)
This fix removes UTC use in the tests.
The quick create popup tried to look up the parent's .string and
.name (or the parent's field_widget's) *but* the calendar view didn't
have a .string, and its .name gave priority to the view's name (as
returned by fields_view_get) as opposed to its @string.
Store the view arch's @string to CalendarView#string, so the quick
create dialog can find and use it.
Replace jquery-ui dialog by bootstrap modal
* fixes general styling (jquery-ui styled heading)
* fixes z-index stacking (jquery-ui dialog appeared on top of
"slow-create" boostrap modal)
* fixes disappeared close button
when a customer invoice is created directly,
if a product variant is selected,
it now computes the price from the product variant and
not from the product template.
opw: 629285