Before this commit, when the user clicks on "Manufactoring" row in
Project Profitability section displayed in right side panel the user
arrives in the tree view if there are more than one record. If he
filters the records and found no record then no help message is shown,
he has just an empty list view.
This commit adds a help message for that action to dislplay it when no
record is shown in the list view (or another view) for this action.
task-2814466
Part-of: odoo/odoo#88219
Before this commit, all rows about timesheets in the revenues of project
profitability section can be clickable and shown the timesheets related
grouped by invoice. However, the invoice is only linked to the
timesheets containing a SOL with the invoice type of the product is set
to 'delivered' and the service_type of this product is set to
'timesheet'. It means only one timesheet row in the revenues has some
timesheets with an invoice linked.
This commit only group by invoice the views in the action called when
the user clicks on 'Timesheet (Billed on Time)' row name.
task-2814466
Part-of: odoo/odoo#88219
Before this commit, by default 10 sales order items are shown in the
Sales section displayed in the right side panel of project update view.
This section takes much place when there are 10 rows by default.
This commit reduces the number of Sales Order Items to 5 records
to display by default when the user arrives in the project update
view with the right side panel. By the way, if the user wants to see
more Sales Order Items, he can click on "Load More" button to see 5
additional Sales Order Items.
task-2814466
Part-of: odoo/odoo#88219
Before this commit, when the user clicks on the Material row shown in
the project profitability section, he can see the SOLs from another
saleman even if he has just the "See own documents" access rights on
Sales app. Moreover, the check to allow the user to click on a SOL name
in Sales section to get either the timesheets and the stock moves
related is done in sudo and so we do not take into account the rules
defined for the current user.
This commit filters the Sales Order Items to show for the user if
he can see the Sales Order(s) related. it removes the sudo to
correctly filter the SOLs and get only the ones accessible by the
current user.
task-2814466
Part-of: odoo/odoo#88219
Before this commit, the user could having a bit difficult to read a
row in Sales or Profitability section shown in right side panel of
project update view since there is not much space between 2 rows.
The idea is to add a color when the user hover a row to correctly see
the row that he sees.
This commit greys a row when the user hovers a row like we did for the
line in the milestone section in the right side panel.
task-2814466
Part-of: odoo/odoo#88219
Before this commit, when the amount is big the monetary symbol is
displayed either above or below the amount associated.
This commit replaces the basic space by a no line break space to keep
the symbol at the same line than the amount.
task-2814466
Part-of: odoo/odoo#88219
Before this commit, when the user clicks on a row in Sales section
displayed in the right side panel of project update, the action display
the list view even if there is only one record to display.
This commit passes the `res_id` with the action to the frontend to
call the action and directly display the form view when we are sure
there is only one record to show.
task-2814466
Part-of: odoo/odoo#88219
Before this commit, when the user clicks on the expense row shown in the
project profitability displayed in the right side panel of the project
update. The action displays the list view instead of directly the form
view.
This commit checks the number of records is equal to one to display the
form view directly if the number is one.
task-2814466
Part-of: odoo/odoo#88219
Before this commit, the context retrieves when the user clicks on a
Profitability section is not parse, and since this context is a string
containing the JS object with the context added, the context is not
correctly added with the existing context.
This commit parses the added context to correctly append it with the
initial one.
task-2814466
Part-of: odoo/odoo#88219
Current access rule requires fetching all members of each channel, which does not scale.
Use is_member field instead, and make sure itself does not fetch all members.
task-2818759
closesodoo/odoo#88221
Related: odoo/upgrade#3422
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
When adding a landed cost and selecting Manufacturing Order, the name of the receipt of the subcontracted products is now shown as well as the MO name for subcontracting orders.
Task: 2667152
Community PR: https://github.com/odoo/odoo/pull/88199closesodoo/odoo#88199
Signed-off-by: Arnold Moyaux <arm@odoo.com>
As social medias can no longer be d-none in the DOM, some code can be
removed from the social media snippet option.
task-2739937
closesodoo/odoo#85476
Related: odoo/upgrade#3292
Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
As social medias are now created dynamically, invisible (d-none) social
medias can be removed from the templates.
task-2739937
Part-of: odoo/odoo#85476
As the s_share options are now shared options between s_share and
s_social_media, the XML option code has to be in a shared file.
task-2739937
Part-of: odoo/odoo#85476
When you compare two products on the ecommerce with the Base Unit Price enabled,
an error occurs.
To reproduce the issue:
1. Install the eCommerce app.
2. Go to the settings of eCommerce and activate the options "Base Unit Price" and "Product Comparison Tool".
3. On the website, go to the shop, and compare two products.
Solution: The XML was passing an invalid argument (unset variable) to the 't-call'.
The argument was in fact unecessary as the argument is already defined in the 't-foreach'.
opw-2802682
closesodoo/odoo#88294
X-original-commit: 91a3a3803c7569ccb755266c8bec2fd7b2a6c315
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
Signed-off-by: Desausoi Laurent (lade) <lade@odoo.com>
On a receipt, when defining the expiration date of a lot, the SML keeps
<today> as expiration date
To reproduce the issue:
1. Edit the operation type "Receipts":
- Show Detailed Operations: True
- Use Existing Lots/Serial Numbers: True
2. Create a product P:
- Type: Storable
- Tracking: By Lots
- Expiration Date: Enabled
3. Create a planned receipt R with 1 x P
4. Mark R as Todo
5. Add a detailed operations:
- 1 x P with new lot L
6. Edit the lot:
- Expiration Date: <today + 7days>
Error: When saving the picking (with the lot updated), the expiration
date is incorrect (set to <today>).
OPW-2785256
closesodoo/odoo#88283
X-original-commit: dd78e43a6286f798c54cf6b3222d3861b9dad34f
Signed-off-by: Steve Van Essche <svs@odoo.com>
Signed-off-by: Adrien Widart <awt@odoo.com>
Before this commit, when the user duplicates a project with subtasks the
subtasks are duplicating twice. This is because we now duplicate the
subtasks when a task is duplicated.
This commit fixes this issue to duplicate once the subtasks when the
project is duplicated.
Steps to reproduce:
==================
1) Create a project A
2) Create a task T with a subtask
3) Duplicate the project A
Expected Behaviour:
==================
The duplicated project should have 2 tasks (subtasks included)
Actual Behaviour:
================
The duplicated project has 3 tasks (subtasks included), the subtask is
duplicated twice.
This bug has been found during the development of task-2726465
Related PR: #86997closesodoo/odoo#88264
X-original-commit: dcf780026bfa7d76a58aa766b8d190022818ce45
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
The tax map was used in a previous version of the invoice template, it
was superceeded by 'tax_details', which uses the
_prepare_edi_tax_details function
closesodoo/odoo#87734
Signed-off-by: Josse Colpaert <jco@odoo.com>
If applied, this commit will fix the following bug by using the price
with the additional cost added instead of only the price
Steps to reproduce:
1- install sales
2- create a product p with variant pv
3- set an extra value for pv
4- go to Products>Product Variants
5- open the pv in form view
6- the Sales Price is the price of p not pv
(which should be p + extra value)
7- also the tax string is calculated on p not pv
Bug:
```list_price``` is being used
Fix:
replace ```list_price``` with ```lst_price```
OPW-2774199
closesodoo/odoo#88270
X-original-commit: 46526f629f7645eaac8ce86e81e806cfa392b8b8
Signed-off-by: William André (wan) <wan@odoo.com>
Issue:
Imagine today is the April 7th 2022 and we set the inventory frequency to 90 days. If our last inventory date was on January 12th 2022, the next inventory date should be set to April 12th 2022. However, it is being set to January 27th 2022 which is wrong.
The next inventory date should be last inventory date + cyclic inventory frequency.
OPW-2795459
closesodoo/odoo#88267
X-original-commit: 990758ebbed294c8f25d90a5e4f6a7455be97a31
Signed-off-by: Arnold Moyaux <arm@odoo.com>
When creating a backorder for a manufacturing order, procure method for
its moves are lost in the process, as the the field is set to copy
False. But the split of a manufacturing order is not a usual copy case.
In this specific case, we need to keep the procure_method of the copied
moves, as it keeps the two/three-steps routes working for the splitted
manufacturing order.
Task-2797359
closesodoo/odoo#88208
Signed-off-by: Arnold Moyaux <arm@odoo.com>
This module replaces both website_sale_coupon and
website_sale_gift_card.
Connects sale_loyalty with website_sale to allow for promotion programs
in eCommerce.
TaskId-2675382
In a subcontracting flow, the extra_cost on the subcontracted production
is read on the purchase line (via _get_price_unit() ) at the production
creation. In case the price unit on this purchase line change before the
validation, the stock valuation layer linked to the production will not
take this new value into account.
This commit ensures the price unit is the right one at validation
Note: the first version of the current fix broke a use case. The test
`test_tracked_compo_and_backorder` has been added to protect that use
case.
closesodoo/odoo#87817
X-original-commit: 1ff1b4a9a2b9ab27b29fdcac93731fa053c77cc7
Signed-off-by: William Henrotin (whe) <whe@odoo.com>
Signed-off-by: Adrien Widart <awt@odoo.com>
Co-authored-by: William Henrotin (whe) <whe@odoo.com>
Co-authored-by: Adrien Widart <awt@odoo.com>
To reproduce:
1. Create a grouped tax with multiple taxes. Reorder the tax
items. (Important step.)
2. Assign tax to the product.
3. Open pos loading the product.
4. a. [BUG] If pos config is tax-included -> non-responsive ui.
4. b. [BUG] If pos config is tax-excluded:
Add the product. -> non-responsive ui.
Fix:
With the new reactivity in owl, mutating reactive objects will
trigger rerender. However, computing tax amount of orderline
or product with grouped taxes result to mutation of a reactive
object, triggering an infinite render (render -> compute with
mutation -> will trigger another render -> ...).
The call to sort is mutating the reactive array referred by
`children_tax_ids`. To prevent this infinite render, the solution
is to use a copy of the array when sorting the taxes.
OPW-2816546
closesodoo/odoo#88245
X-original-commit: b273056a12a34fec75d980e8a4a08ebaedad7e9c
Signed-off-by: Masereel Pierre <pim@odoo.com>
Signed-off-by: Joseph Caburnay (jcb) <jcb@odoo.com>
Inline styles applied by the editor should always have priority over the
general stylesheet. This failed in the case of nested styles (a <font>
with a color within a <span> with a font size for instance).
closesodoo/odoo#88004
Signed-off-by: David Monjoie (dmo) <dmo@odoo.com>
To give a custom style to a template, we need to add a style element at
its top, with the id "design-element", and apply to it the supported
styles. These supported styles and their selectors can be seen in the
`DEFAULT_CSS_OBJECT` constant in `mass_mailing_snippets.js`.
However, comma-separated selectors were not supported, meaning styles
could only be incomplete.
task-2816655
Part-of: odoo/odoo#88004
This module is an unification of `coupon`, `gift_card` and an extraction
of the program models of `pos_loyalty`.
The goal of this module is to unify the creation of coupon, promotion,
gift_card, loyalty programs etc.. into a single base module and share
the same models.
Managers will be able to create programs based on rules and rewards.
Programs may apply on the current order (rules and rewards)
or on future orders, where the rules must match the first order to get a
reward on the second order
or even be nominative and accumulate points over multiple orders.
Every program is based on a point system. And each use of the program
will result in the creation of a coupon (except for nominative programs
which should be limited to one card per customer).
A rule may filter on quantity, money spent and products and give points
on the order, the amount of units paid or the amount of money spent.
A reward could be a free product, a discount or (with an additional
module) free shipping.
Discounts can be percentage based, fixed, or based on the amount of
points the card has.
They can also be filtered on products or tags, to discount specific
products.
A new feature is also being able to select communication plan for these
programs.
The manager can define a template to be sent upon the creation of a new
coupon/card or when reaching a certain amount of points.
TaskId-2675382
For empty list design:
Co-authored-by: Carlos Valverde <cvs@odoo.com>
Due to the recent changes of precompute.
The `tracking` fields of `product.template` would never be filled with
the default 'none' when the module was not loaded.
This means that any new product.product demo/data would fail the upgrade
scripts.
TaskId-2675382