Move the SO part in a new module
Add the functionality to PO
Task 1945220
closesodoo/odoo#33282
Signed-off-by: Quentin De Paoli (qdp) <qdp@openerp.com>
Before this commit when user want to add multiple record at that time
they only allow to add one record at a time.
After this commit user can add multiple record from search more wizard.
Added function _getSearchCreatePopupOptions so that it can be overridden
in FieldMany2ManyTags, options for FieldMany2ManyTags will differ, like
FieldMany2ManyTags SearchCreateDailog should have multi record selection,
Many2ManyTags' SelectCreateDialog should display record other than selected
This commit is related to task id: 1945912
closesodoo/odoo#32453
Signed-off-by: VincentSchippefilt <VincentSchippefilt@users.noreply.github.com>
Co-authored-by: Mohammed Shekha <msh@openerp.com>
Commit 5ef46664a2 share code between produce
wizard and workorder. Field final_lot_id is now commonly used but not very
well named. This commit rename it into finished_lot_id as it represent the
lot number of the finished product.
Task : 1998064
closesodoo/odoo#32761
Signed-off-by: Simon Lejeune (sle) <sle@openerp.com>
When the sales count on the product form doesn't take into account the
sales done in point of sale.
So we've extend the list of done states to take the ones from point of
sale.
TASK-ID: 1985493
closesodoo/odoo#33422
Signed-off-by: pimodoo <pimodoo@users.noreply.github.com>
* We want to limit the obtrusiveness of the mechanism & at the same
time show the warning immediately, so send the warning through a
private channel between the superuser and the admin user rather than
the regular mail.thread's message_post which would likely send the
warning though email.
* Ignore issue when the request comes from a "private" IP (likely a
local dev box where it doesn't matter).
* Only check for "admin" on the admin user: passwords created manually
are already length-checked (required) and strength-checked (visual
indicator).
Task 31122
Supersedes #22428closesodoo/odoo#33254
Signed-off-by: Xavier Morel (xmo) <xmo@odoo.com>
Impacted modules: hr_timesheet, project, sale_timesheet and sale_timesheet_purchase
Currently, the link between the Analytic Account and the Project is non existant if
Timesheets is not installed, and we track any cost linked to the AA set on the Project,
but we only track the revenues linked to Timesheets.
The purpose of this merge is to allow simple project (no timesheet installed or
activated) to track their costs and revenues. This is done through the analytic account; indeed, all
purchase order, sales order, invoices and vendor bills can generate analytic entries. It could
then be interessting for user to see the costs and revenues for a project.
We decided to redirect user from the project dashboard to the "costs/revenues" action of the analytic
account itself, or (if timesheet is allowed on project) to the overview.
This commit also integrates purchase orders on the project overview.
Implementation:
This PR aims to improve the link between Project and Analytic Accounting, by several actions:
* Move all the analytic account business to project
* Add an Other Revenues field in Project Overview, which represent the positive analytic entries
from the AA set on the Project AND that are not linked
to a Timesheet
* Add two smart buttons on Project Overview to Purchase Orders and Vendor Bill of the project's AA
* Add the results (Sales Orders and Timesheets) linked to the project's AA in the respective smart
buttons of Project Overview
* Add a "Profitability" link on the Kanban card of the Project bringing to the Costs & Revenues of
the AA set on the Project to allow profitability tracking when there are no Timesheets.
To do so, it was required to move back the analytic dependency from hr_timesheet to project, like
before 3dd3e26483 (but without the inheritS).
Limitation:
This will only make sense for project having a "one-to-one" relation with analytic account. If 2 projects
are linked to the same AA, we have no way to deduce from which project the cost entry is linked.
Task-1975022
closesodoo/odoo#33237
Signed-off-by: Jérome Maes (jem) <jem@openerp.com>
Have two pos config opened, with at least one connected to a POS box with a printer
Do some sales on both
Click on the printer icon in the pos UI to print today's sales
Before this commit, the ticket that was printed contained sales for
both point of sales
After this commit, it only contains sales of the point of sale from which
the print request has been sent
OPW 1958885
Before this commmit everyone could print the sale datails for all day
for the current PoS Config from the UI.
After this commit cashiers can only print the current session,
disregarding the date.
TASK-ID: 1978713
closesodoo/odoo#33036
Signed-off-by: pimodoo <pimodoo@users.noreply.github.com>
In order to improve the tracking of costs and revenues on projects,
this commit adds a "Profitability" link on the Kanban card of the
Project which appears for analytic accounting users when the
"Timesheets" / "Overview" link does not appear.
This link brings to the tree view of the lines from the analytic
account linked to the project.
Task-1975022
Add two smart buttons in project overview : purchase orders and vendor
bills, linking purchases and bills pointing to the project's analytic
account.
Task-1975022
When we remove the inheritS between project and analytic account, we move the
analytic_accound_id field in timesheet because it was the only use case for
a project to be linked to an analytic account.
This commit prepares new cost origin for a project (other that timesheet).
Register costs on project will required an analytic account to keep analytic
costs tracking. The analytic account management is now moved to project, like
it was in 10.0, but without the inheritS.
Task-1911581
In the SearchPanel there was a separation between selecting and
unfolding a category with children.
With this commit, when the user click to select a parent category the
children are also folded/unfolded.
This reduce the number of actions needed to reach a sub-category.
Task ID: 1917277
closesodoo/odoo#32660
Signed-off-by: Adrien Dieudonné (adr) <adr@odoo.com>
SearchPanel widget in kanban views has been introduced in commit
https://github.com/odoo/odoo/pull/30517/commits/25c9355c02485e85914430188f3281246fc54cda.
But this feature was disabled for mobile.
This commit removes unneeded differentiation between desktop and mobile
for the SearchPanel.
It also adapt related tests to reflect this change.
Task ID: 1917277
The action buttons in the document viewer were badly aligned on small
screens, and specifically when moving to multiple lines to fit on the
viewport.
This commit adjusts the positionning and margins between those buttons
to stay consistent on every screens size (smallest to biggest).
Task ID: 1917277
Widget class indirectly inherits from ParentedMixin (through
PropertiesMixin).
The Widget's children are destroyed in both the ParentedMixin and the
Widget's own destroy() method.
This commit prevents from trying to destroy already destroyed children
and specifically from looping again on those children (resulting into a
minor performance improvement).
closesodoo/odoo#32174
Signed-off-by: Adrien Dieudonné (adr) <adr@odoo.com>
This commit fix non-compliant JS code syntax.
Currently Odoo JavaScript code base supports ECMAScript <= 5 only
Using ECMAScript 6 (2015) feature break compatibility with
Internet Explorer and Android KitKat (4.4)
Ref: https://eslint.org/docs/rules/object-shorthandclosesodoo/odoo#33605
Signed-off-by: Adrien Dieudonné (adr) <adr@odoo.com>
As most of the tests are using demo data, a check is performed to verify
that they are loaded.
A best practice is to write tests that does not depend on demo data but
with this check, it's not possible to launch them without demo data.
With this commit, the check is removed, allowing to launch test even
without demo data loaded.
closesodoo/odoo#33531
Signed-off-by: Christophe Monniez (moc) <moc@odoo.com>
The pdf_viewer widget fails to load file and hence shows error.
This is due to the wrong controller called(wrong URI passed),
while loading a file using pdfjs.
For files other than images, /web/content controller should
be called since since odoo/odoo#31811.
This is similar to the enterprise fix 793c76298a2b301a2
task-1932190
closesodoo/odoo#33354
Signed-off-by: Simon Lejeune (sle) <sle@openerp.com>
Test that there is no conversion of debit/credit when creating a
writeoff with the method process_move_lines of the model
'account.reconciliation.widget'.
See 7b636f3342closesodoo/odoo#33588
Signed-off-by: Cedric Snauwaert (csn) <csn@openerp.com>
Today, some resources that varies very infrequentely are requested on
every page load: the menus, the translations and the qweb templates
After this commit, there will be 2 improvements that will make the
loading of the webclient faster:
1. cache almost static resources forever
when loading the /web/ page, the user session will
contain the cache key to be used to fetch these resources. As the content
of the resource itself it used to compute the hash, the request can be
put in cache by the browser forever (for a year).
The up side is that in general less requests are needed to load the web client
The down side is that the load time and number of queries of /web page
has increased to include what is needed to compute the hash of translations,
menus and qweb templates
2. trigger the loading of the menus before the download (and startup) of
the JS and CSS assets:
The menus contains the definition of the action, wich is the first thing
needed to load a page in odoo. Starting the loading of the menu much
earlier means that when they are not yet in the browser cache (see point 1),
the browser does not need to wait for the entire assets to be downloaded
and parsed before starting the 'load_menu' request, but instead start it
immediately and hold onto a promise to be used instead of the rpc 'load_menu'.
Because the request is done before anything else is loaded, including
JQuery, it is made in vanilla JS.
task-id: 1943338
--
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
closesodoo/odoo#33291
Signed-off-by: VincentSchippefilt <VincentSchippefilt@users.noreply.github.com>
Co-authored-by: Julien Mougenot <jum@odoo.com>
Make `to_refund` true by default as this is ideal for most users. An
override of `default_get` won't work because the field is present in the
view only in debug mode.
Task-1962183
closesodoo/odoo#32495
Signed-off-by: Simon Lejeune (sle) <sle@openerp.com>
Generate a unique URL for translations and cache them forever in the
browser. This reduces the number of requests, in exchange for computing
the hash of the translations when the session object is added to the page
In the HTTP pipeline, there is a middleware called DisableCacheMiddleware
that is called on every request to check if we are in debug mode, to remove
the cache headers and replace them with a static 'no-cache' so the browser
has to contact the server and check for a new version of every ressouce.
There were 2 problems with it:
1. it was doing more work than strictly needed when not in debug, like
rebuilding a list of headers for every request
2. it was removing Etag (case sensitive) with a typo and other headers
that could have been left in place.
This commit fixes those 2 issues by only modifying the headers if we are
in debug mode, and only removing the header 'cache-control' and replacing
it with 'cache-control: no-cache'
* = tools, base, web, website_profile, website_slides
Before this commit it was impossible to pass those parameters in the URL because
they were received as string but expected as int.
The opportunity is also taken to properly use named parameters when calling
`image_process`.
closesodoo/odoo#33506
Signed-off-by: Jérémy Kersten (jke) <jke@openerp.com>
The whole cell is now clickable, not only the first line and it opens
the calendar view.
The meeting title is now displayed on the left, and the time on the right.
Morever, the exact hour is now displayed, not "In 4 hours".
The next activity background color has also been adapted (goes to white).
Task 1948737
closesodoo/odoo#32215
Signed-off-by: Martin Geubelle (mge) <mge@openerp.com>
Today, some resources that varies very infrequentely are requested on
every page load: the menus, the translations and the qweb templates
After this commit, there will be 2 improvements that will make the
loading of the webclient faster:
1. cache almost static resources forever
when loading the /web/ page, the user session will
contain the cache key to be used to fetch these resources. As the content
of the resource itself it used to compute the hash, the request can be
put in cache by the browser forever (for a year).
The up side is that in general less requests are needed to load the web client
The down side is that the load time and number of queries of /web page
has increased to include what is needed to compute the hash of translations,
menus and qweb templates
2. trigger the loading of the menus before the download (and startup) of
the JS and CSS assets:
The menus contains the definition of the action, wich is the first thing
needed to load a page in odoo. Starting the loading of the menu much
earlier means that when they are not yet in the browser cache (see point 1),
the browser does not need to wait for the entire assets to be downloaded
and parsed before starting the 'load_menu' request, but instead start it
immediately and hold onto a promise to be used instead of the rpc 'load_menu'.
Because the request is done before anything else is loaded, including
JQuery, it is made in vanilla JS.
Co-authored-by: Julien Mougenot <jum@odoo.com>
* = partner_autocomplete, point_of_sale, web_editor,
website_forum, website_slides
This can be used for example to preview an image from a file input field.
It can also be used to send the base64 content of the input by RPC instead of
having to rely on form submit as POST with multipart/form-data.
Technically wrap FileReader.readAsDataURL in a Promise.
This will also be used in task-1930726
PR: #33508
Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
After this commit, the order of the elements of the search panel
categories follow the original order received from the back-end.
This is achieved by getting the order from the Array received
from the backend instead of the dictionary used to store the record data.
Task: #1972698closesodoo/odoo#33358
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
This feature was too greedy in term of performance to be computed and not very used.
-task: 1888408
closesodoo/odoo#33500
Signed-off-by: Quentin De Paoli (qdp) <qdp@openerp.com>
This fix an issue in the mobile app in iOS.
Safari is less permissive and a blank page was shown.
closesodoo/odoo#33498
Signed-off-by: Adrien Dieudonné (adr) <adr@odoo.com>
As other modules than survey (namely hr_skills) now need a hook to add specific
behavior when a survey answer is marked as 'done', we removed the '_send_certification'
method and replaced it with a '_mark_done' method.
It will make it easier to override this method as it has a more generic meaning.
closesodoo/odoo#32880
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>