This PR is part of the whole migration of the sale javascript
code and related code to the owl framework.
Why: better developmet framework for javascript code in odoo.
This PR in particular targets the progressbar of sales team
appearing on the CRM app.
Task - 2918635
closesodoo/odoo#95565
Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
> Media query mixins parameters have changed for a more logical approach
> media-breakpoint-down() uses the breakpoint itself instead of the next
> breakpoint (e.g., media-breakpoint-down(lg) instead of
> media-breakpoint-down(md) targets viewports smaller than lg).
> Similarly, the second parameter in media-breakpoint-between() also
> uses the breakpoint itself instead of the next breakpoint (e.g.,
> media-between(sm, lg) instead of media-breakpoint-between(sm, md)
> targets viewports between sm and lg).
https://getbootstrap.com/docs/5.1/migration/#sass
Task ID: 2766483
Part-of: odoo/odoo#95450
Fix some uncommon nightly error on the runbot where a race condition
happened when the tour finished too soon. The test is successful but
during the browser cleanup, things are still happening.
task-2832564
closesodoo/odoo#91920
Related: odoo/enterprise#27600
Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
This commit makes various adapations in addons with respect to
the introduction of the owl kanban view. Mainly, some selectors
in scss and in tests needed to be adapted. Moreover, in some tests
that we haven't adapted yet, we must ensure that legacy form and
list views are still used (useLegacyViews).
It also contains some adaptations in kanban templates, e.g. the
replacement of moment by luxon, the removal of underscore...
Part-of: odoo/odoo#92475
In the sale_signature tour, there was a step for entering auto mode when
signing for a payment. Since now the auto mode is selected by default,
it's not necessary to set it anymore.
task-2862209
closesodoo/odoo#92340
Related: odoo/enterprise#27793
Signed-off-by: Arnaud Joset <arj@odoo.com>
The kanban view for sales team is defined with a progressbar widget to
indicate sales target. There was a .include of KanbanRecord to customize
the behavior of that widget whenever the target value was not set. This
was problematic for the following reasons:
1. it is a .include, so it is applied to all kanban records in odoo
2. it is a lot of code,
3. and it mostly duplicate the editing logic in the progressbar widget
With this commit, the .include is removed, and a new
'sales_team_progressbar' widget is introduced to mimic the previous
customization. This should be safer and easier to maintain.
closesodoo/odoo#92071
Related: odoo/enterprise#27747
Signed-off-by: Géry Debongnie <ged@odoo.com>
Since (at least) Chrome 94+, some element's sizing computation returns a
slightly different value (in the order of a fraction of a pixel). Sadly,
due to rounding, this difference has an impact on exact sizing
assertion.
Specifically in these drag-and-drop tests, it prevents the sorting from
being triggered as the "mouse" doesn't pass beyond the center of the
destination element (aka. next row).
By setting the position to `bottom`, this commit mitigates this issue by
making sure to pass that boundary, just like a real-user would do.
closesodoo/odoo#92292
X-original-commit: ed798b216063caa299800a56c617277aabdfb8fd
Signed-off-by: Adrien Dieudonné (adr) <adr@odoo.com>
Signed-off-by: Pierre Paridans (app) <app@odoo.com>
Before this commit, all the changes were applied to the line one by one.
X-original-commit: 68d3c308df15fccf8e132a2a6ba02542a961495f
Part-of: odoo/odoo#91317
Steps:
Create a product with 2 attributes (2 values each):
> Color: black and white
> Size: small and large
Set their display type to "Pills".
Configure them so that only 2 combinations are possible:
> black - small
> white - large
Go to the website page (product configurator).
The first combination is set. Try to set another one.
Issue:
It is impossible to change neither attributes and, therefore, to change
the combination. With other display types, you can change one attribute,
even if it creates an unavailable combination. You are warned of this
fact, but you can change the other attribute and, by doing so, get back
on another available combination.
Cause:
The stylesheet does not allow to click on an incompatible variant
(attribute value).
Fix:
Delete this property.
opw-2762514
closesodoo/odoo#90236
X-original-commit: 089fda54e383c5f409bab1f2e4c822a4313864e0
Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
Signed-off-by: Onockx Audric (auon) <auon@odoo.com>
This commit adds an higher flexibility to pass optional args through the
price computation methods.
Those optional kwargs offer the opportunity to tune the price
computation, especially to tune the price_compute method on
ProductProduct and ProductTemplate.
On sale order line models, one can define some fields that should be
passed to the price_compute method in order to tune it.
task-2382027
Co-authored-by: Victor Feyens <vfe@odoo.com>
Before this commit, the ProductDiscountWidget (sale.product_discount) worked by overriding the reset method.
The main drawback is that the reset method is called whanever a field on the line is changed.
This commit rely on _onFieldChanged that allows to target single change. A small mixin is created to allow working with different kind of fields of the SOL.
taskid: 2568007
Prior to this commit archived variants would not appear as disabled
in the shop, the different options will now be greyd out if selecting
them would result in an archived variant.
TaskId-2762122
closesodoo/odoo#84711
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
* Remove old unused parameters
* Move `backend_url` logic from qweb to python
* add comments, clean and simplify some code/logic related to portal
page of sale orders
Part-of: odoo/odoo#84644
Reduces load_menus answer size by 32% (between 20kb and 200kb savings
for the initial loading of the backend, depending on the number of apps
installed). Support for SVG icons in the web client for menus/apps.
Reduced PNG icons for apps list (8 bits PNG instead of 24 as our icons
don't need more colors as they are flat designs)
closesodoo/odoo#84280
Related: odoo/enterprise#24200
Signed-off-by: Fabien Pinckaers <fp@odoo.com>
- If we only install sales_team, on the footer of sale team kanban view
there's empty grey border which looks ugly. Also, if the data are
not available, the empty graphs don't look so beautifull.
This commit improves the kanban view to avoid this empty grey border
when there's no content within it, and in case of lack of the data,
we now display sample data in graph with grey color. Note that the
actual data now has colors, green for the future / present data range
and pink for the past ones.
- When opening the configuration menu of team kanban from CRM, we observe
three columns: View, New and Reporting. However, those columns are not
consistent. For example, when leads are activated, we don't see 'Leads'
action under 'New' column. Also the order for the actions are not
consistent for 'View' and 'Reporting' columns.
This commit re-organizes the sequence of the actions for these columns
and thus makes them consistent. Note that we want to always show the
'Activites' at the last, which is being added from crm with 'Leads' and
'Opportunities' actions. So an empty seperator is introduced to keep
them seperate, and push the sales related actions on the top of
'Activities'.
- Right now, the alias on sales team's kanban view is being shown
with `<small>` tag, but it is hard to read. Apart from that, in
the list view, only the alias name is displayed even if the alias
domain is configured.
This commit makes the alias more easy to read by displaying it
with `<span>` tag on the kanban view, and by showing the full
alias along with the domain on list view. Note that on the kanban view,
alias will now be displayed always, which previously was displayed only
when 'leads' were enabled.
- This commit also changes of the action 'crm_activity_report_action' from
'Pipeline Activities' to simply 'Activities' to avoid confusion.
- Apart from that, this commit also adds currency symbol in the form
view and kanban view (while configuring the target), with the suffix
' / month' after the input. Adds the alias name in the
team list view, and it adds 'many2one_avatar_user' widget on user_id
field for both list and form view.
TaskID-2582208
Part-of: odoo/odoo#73530
The changes concern the following modules:
- sale
- sale_product_configurator
- website_sale
- website_sale_product_configurator
When optional products are enabled and a user adds an item to the cart, the
modal popup does not allow further modifications to the main product based
on its template. If the user wants to change the color or the material, they
have to close the popup, modify the product and open it back up.
The same is applied when Add to Cart is active, and the user cannot configure
the product at all after clicking the add to cart button.
This change will make it possible to change the product variants without having
to close the modal, and configure the product when using the "Add to cart"
button when it's enabled.
The added configuration step is needed for some cases like the following:
1. When adding a product that had variants directly from the /shop page before,
the first variant was added by default and configuring it was impossible without
explicitly going on the product's page and configuring it from there. This
behaviour made no sense, and it's the reason the "optional products modal"
(which should no longer be called that) is opened when the product is not
configured even if there are no optional products.
2. When going through the product's page, and there are optional products enabled
for the product getting configured, then it's nice but not necessary to be able to
configure the product further while choosing and configuring the optional products.
This doesn't add an extra step in any case, it just makes it possible to still configure
your product in the modal.
3. If there are no optional products, the configuration made on the product's
page is taken into account and the product is directly added to the cart without
opening the modal, which is the same behaviour as previously.
Only one modal is shown, depending on the situation:
- For the website flow, if the product is not configured and has variants or has
optional products (or both), a popup shows that allows for configuration +
choosing and configuring optional products.
- For the sales flow, there was already a configuration popup, so the optional
products modal is only shown when there are optional products and replaces
the first instead.
Some tests were adapted to function with the new product configuration modal:
- The steps checking for the text mentioned above are removed
- Triggers were adapted to the modal for products that were previously added to cart
with their default variant
- Various other small adjustments
task-2541663
closesodoo/odoo#73086
Signed-off-by: Romain Derie <rdeodoo@users.noreply.github.com>
The bubble on the invoice view, made the list slightly difficult to read.
It is a little bit better on the right.
closesodoo/odoo#73768
Task: 2476548
Signed-off-by: Laurent Smet <smetl@users.noreply.github.com>
Requires markup every markup-using tip content as Markup. Would be a
nice occasion to migrate everything to a markup-safe markdown I think,
especially if we could migrate the translations so we don't lose them.
The tour bubble "animation" that makes it to bounce up and down can cause
issues when its position is at the edge of the bottom of the screen.
In the sale tour, this would make the window constantly resize to show a
scrollbar and then resize to hide the scrollbar, creating quite a sickening
effect visually.
closesodoo/odoo#72485
Task-id: 2480195
X-original-commit: 8511d2352776a63fa2483dafac91a496d45461c1
Related: odoo/enterprise#19147
Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
A product with single novariant attribute is normally not shown.
But in the configurator modal it was shown and then added in the product
description when doing exactly the same scenario (add the product) than
without the configurator.
With this changeset, we add is_single attribute and only add a no_create
variant if it is not a single value or a custom value.
opw-2494331
closesodoo/odoo#70700
X-original-commit: 9bd32f2a36eae1713753bf7a5a1aee3b5c51a97a
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
Same reason that cdb7a8ad7647649ad8f595454aa9dc0464117568
The tour bubble animation might cause the page to flicker since the
scrollbar might appear disappear depending on size of modal / browser.
opw-2469248
closesodoo/odoo#69652
X-original-commit: 7405d2a38728d11a5a96c115d7c0c0320dd5ac8e
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
*: portal, portal_rating, product, sale, sale_product_configurator,
website, website_sale_comparison, website_sale_product_configurator,
website_sale_stock, website_sale_wishlist, point_of_sale
Redesign of the product page + various UX improvements.
task-2009483
Part of #66736
This commit replaces the old online payments API of the `payment`
module with the new one and adapts to it all the implementing modules.
See the merge commit for more details.
task-2085989
task-2119838
task-2165982
task-2289255
Co-authored-by: Victor Feyens <vfe@odoo.com>
Issue
- Install 'Sale', 'Inventory' and
'Sale Product Configurator' module
- Create a product X with the following attributes:
attr1 : val1, val2
attr2 : val3, val4
- Click on 'Configure Variant'
- Select val3 and add exclude for val1
- Select val4 and add exclude for val2
- Go to 'Sales' and create a 'Sale Order'
- Select product X (a wizard should open)
Can't change option combinaison.
Cause
Options combinaison (that are not allowed) are disabled.
This commit introduce the error:
https://github.com/odoo/odoo/commit/6150311b72089e3fbae6bc27551bc7f4792e68dd
Solution
revert commit.
opw-2478854
closesodoo/odoo#68401
X-original-commit: 0a92706cd0d38d33a399bec7b5b5fbe7ab7f8576
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
Signed-off-by: bon-odoo <nboulif@users.noreply.github.com>
The popup to apply the discount of the first SO line to the other lines didn't appear
when the first line was a section or a note.
closesodoo/odoo#67907
X-original-commit: 995ba0c2033455a2092439e9728b3f731381c742
Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
Issue
- Install "Sales" module
- Go to settings and activate "Product Configurator" feature
- Create a product X with mutilple color (variants)
- Create a quotation
- Add product X (Product Configurator should open)
- Hover any color
Popup with color name does not appear.
Cause
'title' attribute value is removed.
Solution
if element have 'value_name' data attribute, set it back as title else set no title.
opw-2438704
closesodoo/odoo#66479
X-original-commit: fc7ef284915641472722a7be06a75b1df3b8ca93
Signed-off-by: bon-odoo <nboulif@users.noreply.github.com>
with this commit we are updating sequence of onboarding tours
task-2444153
closesodoo/odoo#65244
X-original-commit: a928beccb09f4db4234356e5e4f7bdf090ecc964
Related: odoo/enterprise#16026
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
with this commit we fixes various tour steps, remove steps from crm and sale
tour and improve step selector in project tour.
task-2444272
closesodoo/odoo#65073
X-original-commit: f6c05693f857acfb0f74bb76c4bd72f83d9fb335
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
Steps to reproduce the bug:
- Let's consider a product P with a blocking message BM
- Create a quotation Q and set P on it
Bug:
A traceback was raised.
opw:2421946
closesodoo/odoo#63853
X-original-commit: e0af10ccc92cb3b07f0eea6fa44ebf5a1bdc86aa
Signed-off-by: Simon Goffin (sig) <sig@openerp.com>
Depending of the configuration, on the portal, anchor do not consider the
header, so a part of the text is hidden by the navbar.
task-2290213
closesodoo/odoo#60415
X-original-commit: 2cd9a9d12f4cd7352430c166145a7488af0c120c
Signed-off-by: Jérémy Kersten (jke) <jke@openerp.com>
Signed-off-by: Romain Derie <rdeodoo@users.noreply.github.com>
This commit fix the fw port https://github.com/odoo/odoo/pull/58149
which does not work in all scenario
Create a sale order
Put an optional product with long description (no line break)
Save and confirm
Log in the portal with the receiving user, add the optional product to
the order.
The customer can't see the quantity of the optional product.
The number is not showing in the quantity adjustment widet.
opw-2350879
closesodoo/odoo#59801
X-original-commit: 9a91fe7d6064475bc949a5c2aee883ea2f419930
Signed-off-by: agr-odoo <agr-odoo@users.noreply.github.com>
Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
1. Lead to loose the tour: Remove the step of the tour that asks
to set an address (the address is auto-completed at free trial
based on domain name).
2. Bug: At step 3, it redirects to the
invoice settings to select a localization, when you click on
"install more packages", you are sent back to the sales app.
--> this bug is related to res_config_settings.js from base addon.
I tried to fix this bug by adding a data-attribute "discard" in the
res_config_settings_views and checking this additional condition in
the js.
3. Bug: Tour blocks at last step "send by email" on quotation.
After clicking on "sent" on the pop-up, there should be rainbow
effect to mark the end of the tour.
4. Bug: Sale order line: fix the blue color on Invoiced Quantity
only, instead of the full line
5. Put the "sample product" in active= false (it's necessary for
the sample invoice but should not be visible to the user, they
should create their own)
6. Merge the 2 dates fields related to expected delivery on sale.order
--> since other modules extends this module, I made the field
expected_date invisible and put the same value in both fields. This
value is the max of the order_lines.expected_date
closesodoo/odoo#59261
Taskid: 2277314
X-original-commit: 0f81816d4ddb0febd28f6c6bb5dd50ae570333e1
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
Create a sale order
Put an optional product with long description (no line break)
Save and confirm
Log in the portal with the receiving user, add the optional product to
the order.
The customer can't see the quantity of the optional product.
The number is not showing in the quantity adjustment widet.
opw-2304224
closesodoo/odoo#58226
X-original-commit: 27f6522f43c38d8eeed32285ce03fd1bb218aab2
Signed-off-by: agr-odoo <agr-odoo@users.noreply.github.com>
Purpose of the task is, all users have access to activities and will
see "empty" icon on systray activity list and won't understand why it
doesn't show. so to favour majority user add the icon to sale module.
So in this commit added the icon to the sale moduel so we can see the
icon in the systray activity list.
closes odoo/odoo#55714
Taskid: 2312117
Closes: #55714
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
Purpose fo the task is to Allow changing a discount for the whole SO.
So in this commit, On a quotation, with "discount per line" option
enabled, if the user changes the discount on the first SO line, display
a pop-up requesting if they want to apply the change to all the lines
of the SO.
There is condition to open the confirmation dialog to change on all SO lines:
1. There should be 3 or more lines in SO
2. Happens only when changing the discount of the first SO line
3. The initial discount is the same on all lines
For Ex: Example : a SO with a discount of 10% on all 6 SO lines.
The user clicks the discount field on the first so line, changes to 20%.
A pop-up "apply this discount to all quotation lines"
-> if yes, apply 20% to all SO lines.
closes odoo/odoo#54262
Taskid: 2276759
Closes: #54262
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
Issue
- Safari
- Sales with product configurator
- Have a product with color black & white
size M, XL
- Exclude M size when color is white
- Create a SO with that product
- Select white color
The size's M option is not grayed in the select
Cause
We do not disable the option when it's not available.
We are just adding a css class which grays the option.
Safari ignores the style
Solution
Since the flow can't be completed if you select a
grayed item, disable the option
OPW-2289666
closesodoo/odoo#54993
X-original-commit: 6150311b72089e3fbae6bc27551bc7f4792e68dd
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
Signed-off-by: Jason Van Malder (jvm) <jvm@odoo.com>
* The first tour is starting in the sale app dashboard and ensures
the user goes through the needed configuration steps
* The second tour starts in the new Quote form and shows the flow to
send a quote to a customer
TaskID: 2187222
Closes: #46167
Issue
- Install eCommerce
- Create a SO
- Add a section
- Add a note with big text
- Customer Preview
The word are not broken correctly
Cause
We added a break-all to prevent
long URL/words overflow.
Solution
Use work-break: break-word which
will break the word correctly.
Use overflow-wrap/word-wrap
(same usage but we need both
to ensure browsers compatibility)
which makes sure the long string
will wrap and not bust out of the
container
OPW-2222814
closesodoo/odoo#49321
X-original-commit: 0754590abe1b84874aa2a685fea5cbf2569383e4
Signed-off-by: Jason Van Malder (jvm) <jvm@odoo.com>
This commit is another fine-tuning of 348a5d0.
The buttons size is sometimes problematic so
we should reduce it.
OPW-2220893
closesodoo/odoo#49227
X-original-commit: 57999ea32c0cc85283faf06f6edb8649af784838
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
This commit is a fine tuning of 348a5d0a6.
It fixes the same issue but for larger screens
with some themes (e.g. Orchid).
When there are big button to chose the quantity,
this padding is hiding the input's text.
Another solution would be to remove `width: 50%`
but I found that removing the padding is prettier.
OPW-2220893
closesodoo/odoo#48934
X-original-commit: 105a34accc6123cfb6be9738858499737df95613
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
Issue
- Install eCommerce with any theme
- Website > Enable optional product
- Create a SO with an optional product
- Save > Customer Preview
- Mobile view with inspector
- Click on the shopping cart icon in
the optional product line
Quantity selector is not correctly
displayed
Cause
First, the input width is 50%, which
means very small on mobile and there
are paddings on the input and the buttons
Solution
Remove the 50% width and paddings on mobile
It allows to see 3 chars on very small
mobile screen.
OPW-2220893
closesodoo/odoo#48423
X-original-commit: 38e90e09239eb75bd25001c7870758b380159ad0
Signed-off-by: Jason Van Malder (jvm) <jvm@odoo.com>
*sale_product_configurator
Since commit 50bf830, a crash occurred when a row containing a
many2one displayed with widget 'product_configurator' was dragged
and dropped.
For instance, open a quotation with at least two rows, and drag and
drop one of them.
Issue reported on task 2206228
closesodoo/odoo#48128
X-original-commit: d9c35b40b7df588f9e81142a2b272d9c7da06e04
Signed-off-by: Lucas Perais (lpe) <lpe@odoo.com>
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
This commit moves some step utils in a dedicated file and add new ones.
These steps will be very useful for the Main Flow Tour to avoid
duplicated code.
To do this, we also had to transform it into functions to allow
utils to call each other. Existing one are converted for
standardization purpose.
Note that 'WEBSITE_NEW_PAGE' wasn't considered as an util.
This is a very simple step only used twice.
Issue
- Install Sale
- Create SO
- Add a note line with a very looong word
- Print PDF
No line break, table is expending out of
the visible report.
Cause
There is no line break CSS rule
Solution
Use word-break: break-word; in order to
break line without cutting words.
OPW-2195984
closesodoo/odoo#47272
X-original-commit: af8fb786a9569562cefb7d8ea63454cddc04cd44
Signed-off-by: Jason Van Malder (jvm) <jvm@odoo.com>