Currently, to remove link of x2m field from any record, sometimes there's no way.
For example, if we are on mobile and open any Quotation, it's linked quotation lines
are automatically converted in kanban, and there is no way to delete a line from
that quotation. However, in some of the manually designed kanban, there is special 'x'
for removing / unlinking x2m record, for example, Contacts of Partner.
This commit makes the behavior more consistent. During edition (mobile and desktop), if
a view dialog is opened on click of x2m field, it will have one 'Remove' button (based
on user rights) on right side of dialog footer, allowing users to delete / unlink the
record. Moreover, in mobile, the modal is opened fullscreen, with sticky header and
footer.
Related Task# : 31641
Closes PR #15857
Co-authored-by: Mohammed Shekha <msh@openerp.com>
Factur-x is the e-invoicing standard in vigor in FR & DE and, by extension, it will probably become the standard in Europe. Thus this will be used as default e-invoicing standard by Odoo.
The idea is simple:
* when printing your customer invoice report (not in draft ofc), a Factur-x xml file is generated and embedded inside the PDF.
* when importing supplier bills in the form of PDF files, we detect if any Factur-x xml file is attached and complete the data of the draft vendor bill accordingly. This is done during the message_post() function.
/!\ To be compliant with the Factur-x standard, the PDF should be PDF/A-3b compliant. (See: http://fnfe-mpe.org/wp-content/uploads/2018/07/1.-FACTUR-X-V1.1-2018-07-24-FR.pdf chapter 6)
However, wkhtmltopdf is not PDF/A compliant and then, the generated PDF report are not fully compliant with the Factur-x standard.
Was task: 1859277
Was PR #25508
Suggestions made to reconcile bank statement lines are now more accurate (based on communication and amount)
There's no automatic mode anymore (button + <CTRL+ENTER> shortcut removed)
Partners are set automatically when selecting a line in the widget (that will help the creation of a res.partner.bank for him, for a better partner detection next time)
Was task: 1847703
Was PR #25438
The indentation of the computation of date_deadline was incorect
leading to a deadline only getting compute when the base date was
depending on a previous activity.
Before this commit, `testUtils.unpatch` was incorrectly
unpatching a class' properties.
That is caused by restoring the properties on the class
function itself, instead of the prototype of the class
function.
This commit fixes this issue by restoring properties on the
prototype function of the class on `testUtils.unpatch`.
Some aria HTML attributes were missing, and are desirable to provide a
better experience for screen reader users.
The following attributes are included:
- `aria-pressed`: Used in buttons whose function is toggled when
pressed. In this case, it is added on the button to follow/unfollow
a record.
- `role`: used to improve given information about what elements are for.
In this case, it is added in the following cases:
1. Buttons to apply filters (e.g. to filter conversations) are set
to role="tab". These buttons have the class `o_filter_button`.
2. Elements who are not buttons but have the class `dropdown-menu`
are set to role="button".
Closes#25667
When a Chrome headless test fails the browser is not cleaned and could
lead to a mix with other tests when the same method is called.
Also, the multiline assertions gives an unreadable message when the
assertion fails.
Finally, it happens that a thread does not have an 'url' attribute and lead to a crash when the logger tries to show the thread url.
With this commit, the browser is cleaned, even on failure and the
assertions are now one line.
Closes: #26432
Revision on https://github.com/odoo/odoo/commit/f2302dfb27dd7f6a0dee7c65ab75b62a01706264
The commit above improved the rendering of thread.
However, it wrongly defined ASC and DESC.
This commit fixes this issue by re-arranging so that their
definitions match the meaning of 'ascending' and
'descending'.
Orders are defined from top to bottom. Visually:
_____________ _____________
| | | |
| message 1 | | message n |
| message 2 | | ... |
| ... | | message 2 |
| message n | | message 1 |
|_____________| |_____________|
ORDER: ASC DESC
The activity was incorrectly scheduled with a deadline as the now in UTC while
the state was computed using "today" in the user's timezone.
This made the nightly test fail (run at 23:30 UTC with the user in UTC+2).
Use context_today instead of today for all activity_schedule calls
To make it easier, use on the context_today default value instead of setting
context_today everywhere (which is more error prone in the future)
Never use datetime, only date objects
add a warning to detect potential errors when passing a datetime
Closes#26411
1. Odoobot shouldn't talk to admin when demo data are installed
Odoobot will talk to a user on it's first connection, meaning that
a dev will see this chat window a lot. The state disabled is not a
real state but is explicit, the odoobot wont be initialized in this
case. It is still possible to test odoobot flow with demo user.
2. remove old odoobot image and update link
3. small improvements in odoobot answers
example: <field name="product_id" options="{'no_open': True}" readonly="1"/>
This has been broken by rev. 43d21dd9c due to misplaced parentheses
(an empty object in javascript being truthy).
Before this commit, the method _document_check_access would succeed if it was called with a non-existing id.
Now it will raise a MissingError.
PR: none
Task: none
Sales Order report:
- fix Total table alignment (to the right)
- remove misplaced /> characters
- remove page-break before optional products
Sales assets:
- fix duplicate ID preventing assets files from being loaded
My Home:
- fix link to sales orders
Optional Products:
- renamed various strings
- made product_id required to prevent a traceback
PR: none
Task: 1838924, 1876864
The search view always instantiates a time range menu but hides it
when it is not used.
Now, when the time range menu is not used, every time the search view
facets are rendered, the time range menu is also rendered entirely
and becomes visible shortly before being hide again. This caused
a bad screen flickering.
This commit fixes that problem by avoidind the unnecessary rendering of
the time range menu.
Revision on https://github.com/odoo/odoo/commit/e0a51edd856b36bfdf1cacb4d7e8d70fad7884fa
In the commit above, we added an option to Discuss widget
to render threads specifically for PhantomJS. The reason
for this is that a test was failing, because it needs full
support of CSS flexbox to pass.
However, PhantomJS does not support flexbox very well. As
a result, it was messing with the rendering of threads.
We couldn't make the hack just in the test itself, because
it is already at the moment of rendering the thread that
PhantomJS messes the whole process of the test.
PhantomJS has been replaced with Chrome headless [1], So
the hack is no longer be necessary, as Chrome headless
fully supports CSS flexbox.
[1] https://github.com/odoo/odoo/commit/de84ad9c1f4853cb8a748ee1d0c880081dae9fe2
Revision on https://github.com/odoo/odoo/commit/10f43955d81ff3e7b5ab050656b312ec19f927c5
Commit above uses `testUtils.patch` in the test.
However, this utility function does not seem to work.
That sucks...
No advantage to group a search on purchase.order and another one on
account.invoice.
Avoid potential access errors if a user has access to one model but not the
other one.
Closes#25761
The most important part of building salary rules is having them in the right
sequence. Unsure all the rules are evaluated in a deterministic order.
This also makes it easier to know how the payslip will show the order of the
salary rules.
Closes#25756
The lib 'nvd3' renders graph when they are attached to the
DOM. However, widgets are rendered in fragments and
appended to the DOM when ready (to prevent flickering).
Before this commit, we used a `setTimeout(0)` and cross
fingers that the widget was attached to the DOM when the
`render` method was called.
With this commit, the render method is called when it is
attached to the DOM.
Task-ID 1868252
Closes#26410
The account module needs to import Form from "tests.common" causing a
traceback when websocket-client module is not installed.
As this module is only required for the tests, there is no reason to add
it to the "requirements.txt" file.
With this commit, Odoo account can be installed even when
websocket-client is not installed, in that case, the HttpCase tests that
needs to run Chrome headless will be skipped with a warning.
Closes: #26404
Usecase to reproduce:
- Check manufacture to resupply and manufacture in 2 or 3 steps
- Uncheck manufacture to resupply
pbm and sam rules in global route(mto/manufacture) are still active
It happens because the condition to archive the rules was not complete
the check on manufacture to resupply was missing