Commit Graph
198 Commits
Author SHA1 Message Date
Horacio Tellez bf3942b553 [IMP] sale: progressbar js logic migration to owl framework
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

closes odoo/odoo#95565

Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
2022-08-08 10:50:54 +02:00
Romeo Fragomeli 1fcd098af5 [REF] *: BS5: migration
Automated change made by a lot of RegEx to change all think that is
possible to automate.

https://getbootstrap.com/docs/5.1/migration

Task ID: 2766483

Part-of: odoo/odoo#95450
2022-07-07 13:30:24 +02:00
Romeo Fragomeli 9b5c9484fe [REF] *: BS5: adapt changes in media query mixin
> 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
2022-07-07 13:30:24 +02:00
Demesmaeker 08aff3b686 [FIX] (test_)sale(_product_configurators): fix nightly race condition
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

closes odoo/odoo#91920

Related: odoo/enterprise#27600
Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
2022-06-30 18:51:54 +02:00
Aaron Bohy 4f984568e1 [REF] *: adapt code to new kanban view
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
2022-06-30 09:29:45 +02:00
Leonardo Pavan Rocha 4e62c2847f [FIX] sale: remove click auto tour step
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

closes odoo/odoo#92340

Related: odoo/enterprise#27793
Signed-off-by: Arnaud Joset <arj@odoo.com>
2022-06-03 12:02:17 +02:00
Géry Debongnie 95880ab7b4 [REF] sale: simplify code for sales team progressbar
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.

closes odoo/odoo#92071

Related: odoo/enterprise#27747
Signed-off-by: Géry Debongnie <ged@odoo.com>
2022-05-25 20:31:42 +02:00
Pierre Paridans 333a4e8733 [FIX] purchase_product_matrix: test breaking in newer Chrome (rounding)
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.

closes odoo/odoo#92292

X-original-commit: ed798b216063caa299800a56c617277aabdfb8fd
Signed-off-by: Adrien Dieudonné (adr) <adr@odoo.com>
Signed-off-by: Pierre Paridans (app) <app@odoo.com>
2022-05-25 18:01:03 +02:00
Arnaud Joset 5df841123d [FIX] sale: make update all widget work in batch
Before this commit, all the changes were applied to the line one by one.

X-original-commit: 68d3c308df15fccf8e132a2a6ba02542a961495f
Part-of: odoo/odoo#91317
2022-05-18 12:00:03 +02:00
Audric Onockx (auon) cdd428525e [FIX] sale: allow to select incompatible variants with pill display
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

closes odoo/odoo#90236

X-original-commit: 089fda54e383c5f409bab1f2e4c822a4313864e0
Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
Signed-off-by: Onockx Audric (auon) <auon@odoo.com>
2022-05-02 18:48:49 +02:00
Thibault LibioulleandVictor Feyens a7f30ce917 [IMP] product,sale: factorize price methods to improve inheritability
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>
2022-04-14 14:33:23 +02:00
Arnaud Joset 44dc3910e2 [IMP] sale: create a JS mixin to update all discounts value
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
2022-04-07 13:23:09 +02:00
William Braeckman 2a1928eef7 [IMP] website_sale: disable archived variants
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

closes odoo/odoo#84711

Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2022-03-28 21:45:49 +02:00
Victor Feyens 213e0ba734 [IMP] sale: clean sale order portal page rendering
* 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
2022-02-28 14:46:56 +00:00
Fabien Pinckaers 10a5796d4b [IMP] speed up load_menus() by using SVG icons instead of png
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)

closes odoo/odoo#84280

Related: odoo/enterprise#24200
Signed-off-by: Fabien Pinckaers <fp@odoo.com>
2022-02-12 08:55:18 +00:00
+2 318cdcc0b8 [REF] *: adapt code to owl 2
Owl 2 changelog: https://github.com/odoo/owl/blob/a9f29c4caad4f32d06be1ec4780572825781cd9b/CHANGELOG.md

Part-of: odoo/odoo#80156
Co-authored-by: Aaron Bohy <aab@odoo.com>
Co-authored-by: Bruno Boi <boi@odoo.com>
Co-authored-by: Géry Debongnie <ged@odoo.com>
Co-authored-by: Samuel Degueldre <sad@odoo.com>
Co-authored-by: Mathieu Duckerts-Antoine <dam@odoo.com>
Co-authored-by: Simon Genin (ges) <ges@odoo.com>
Co-authored-by: Francois (fge) <fge@odoo.com>
Co-authored-by: Michael Mattiello (mcm) <mcm@odoo.com>
Co-authored-by: Julien Mougenot <jum@odoo.com>
Co-authored-by: luvi <luvi@odoo.com>
Co-authored-by: Lucas Perais (lpe) <lpe@odoo.com>
Co-authored-by: Jorge Pinna Puissant <jpp@odoo.com>
2022-02-10 07:46:13 +00:00
stefanorigano (SRI) d063d99e15 [REF] product, *: update demo-data images
task#2667024

Part-of: odoo/odoo#79651
2021-11-16 13:03:03 +00:00
stefanorigano (SRI) 8ff203e068 [FIX] sale, website_sale, *: fix product's page cta block design
task#2667024

Part-of: odoo/odoo#79651
2021-11-16 13:03:00 +00:00
ijas ahammed 4c271090c4 [IMP] crm,{sale}s_team: improve the sales team kanban/list/form UI
- 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
2021-09-06 08:21:29 +00:00
Kamen Zhekov 2b832269f4 [IMP] sale*: merge configuring products and opt. products modals
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

closes odoo/odoo#73086

Signed-off-by: Romain Derie <rdeodoo@users.noreply.github.com>
2021-08-30 13:27:44 +00:00
John (jol) 67dac2ad3a [IMP] account,sale: move tour bubbles on invoice view
The bubble on the invoice view, made the list slightly difficult to read.

It is a little bit better on the right.

closes odoo/odoo#73768

Task: 2476548
Signed-off-by: Laurent Smet <smetl@users.noreply.github.com>
2021-07-27 08:56:53 +00:00
Xavier Morel 0e552b96da [FIX] *: convert tip contents to t-out
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.
2021-07-20 05:40:55 +00:00
Prakash Prajapati 30296026f9 [FIX] account, purchase, sale: reposition tooltip to avoid resize flicker
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.

closes odoo/odoo#72485

Task-id: 2480195
X-original-commit: 8511d2352776a63fa2483dafac91a496d45461c1
Related: odoo/enterprise#19147
Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
2021-06-21 18:11:31 +00:00
Sébastien Theys c6716847aa [IMP] web, *: clean up notification API
task-2476867

closes odoo/odoo#67009

Related: odoo/enterprise#16760
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2021-05-27 13:47:23 +00:00
Nicolas Lempereur f810e00332 [FIX] sale: no show single novariant attribute in configurator
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

closes odoo/odoo#70700

X-original-commit: 9bd32f2a36eae1713753bf7a5a1aee3b5c51a97a
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
2021-05-11 15:56:42 +00:00
Nicolas Lempereur dd9d4c2566 [FIX] sale: reposition tooltip to avoid resize flicker
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

closes odoo/odoo#69652

X-original-commit: 7405d2a38728d11a5a96c115d7c0c0320dd5ac8e
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
2021-04-22 09:44:30 +00:00
Benjamin Vray 3e03bd9a39 [IMP] website_sale, *: redesign the product page for e-commerce
*: 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
2021-04-01 14:56:36 +00:00
Antoine Vandevenne (anv)andVictor Feyens 573ed74c12 [REF] payment, *: refactor online payments API
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>
2021-03-30 09:25:51 +02:00
Nasreddin (bon) 2ebb327a9a [FIX] sale: allow select any product combination
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

closes odoo/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>
2021-03-26 13:36:07 +00:00
Florent de Labarre 0a7883dd87 [FIX] sale: show discount popup for orders beginning with a section/note
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.

closes odoo/odoo#67907

X-original-commit: 995ba0c2033455a2092439e9728b3f731381c742
Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
2021-03-15 21:42:04 +00:00
Nasreddin (bon) 8d3950d8d7 [FIX] sale: Display color tootlip in product configurator
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

closes odoo/odoo#66479

X-original-commit: fc7ef284915641472722a7be06a75b1df3b8ca93
Signed-off-by: bon-odoo <nboulif@users.noreply.github.com>
2021-02-18 15:00:13 +00:00
Mohammed Shekha 706929e118 [FIX] *: update tour sequence
with this commit we are updating sequence of onboarding tours

task-2444153

closes odoo/odoo#65244

X-original-commit: a928beccb09f4db4234356e5e4f7bdf090ecc964
Related: odoo/enterprise#16026
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
2021-01-29 09:03:08 +00:00
Mohammed Shekha 78ab4bde80 [FIX] *: various tour fixes
with this commit we fixes various tour steps, remove steps from crm and sale
tour and improve step selector in project tour.

task-2444272

closes odoo/odoo#65073

X-original-commit: f6c05693f857acfb0f74bb76c4bd72f83d9fb335
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
2021-01-26 15:51:04 +00:00
Goffin Simon a6a1d52b4e [FIX] sale: Product with a blocking warning raises a traceback
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

closes odoo/odoo#63853

X-original-commit: e0af10ccc92cb3b07f0eea6fa44ebf5a1bdc86aa
Signed-off-by: Simon Goffin (sig) <sig@openerp.com>
2020-12-28 16:59:10 +00:00
Romain Derie 6bf6688d73 [FIX] portal, sale: scroll correctly if fixed header
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

closes odoo/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>
2020-10-21 09:17:14 +00:00
Andrea Grazioso (agr-odoo) 066f4ec97c [FIX] sale: fix quantity non visible in portal
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

closes odoo/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>
2020-10-12 17:01:02 +00:00
Pierre Collinet (pic) 7b368e7215 [FIX] sale: Apply several fix on sales tour
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

closes odoo/odoo#59261

Taskid: 2277314
X-original-commit: 0f81816d4ddb0febd28f6c6bb5dd50ae570333e1
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2020-10-06 11:57:55 +00:00
Andrea Grazioso (agr-odoo) da716fc115 [FIX] sale: fix quantity non visible in portal
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

closes odoo/odoo#58226

X-original-commit: 27f6522f43c38d8eeed32285ce03fd1bb218aab2
Signed-off-by: agr-odoo <agr-odoo@users.noreply.github.com>
2020-09-22 12:57:08 +00:00
shivam shah 570e7c5972 [IMP] sale: Add icon to sale module same as sale_management
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>
2020-08-11 08:36:36 +00:00
Prakash Prajapati 696ea173d3 [IMP] sale: Apply discount on all SO lines onchage of first SO line
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>
2020-07-16 10:22:57 +00:00
Jason Van Malder 974bc0d2df [FIX] sale: fix safari excluded variant indistinguishable in select
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

closes odoo/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>
2020-07-27 14:49:18 +00:00
Julien Mougenot c4786fccfd [IMP] *: update notifications to optional title
closes odoo/odoo#52826

Related: odoo/enterprise#11084
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
2020-06-12 09:01:50 +00:00
Laurent Stukkens (LTU) 557582e88b [IMP] sale: Improve the onboarding tours
* 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
2020-05-07 13:23:07 +00:00
jvm-odoo 8ba5e135ef [FIX] sale: fix SO preview word break
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

closes odoo/odoo#49321

X-original-commit: 0754590abe1b84874aa2a685fea5cbf2569383e4
Signed-off-by: Jason Van Malder (jvm) <jvm@odoo.com>
2020-04-09 12:27:17 +00:00
jvm-odoo 50caf4d6b4 [FIX] sale: fix quantity buttons size
This commit is another fine-tuning of 348a5d0.
The buttons size is sometimes problematic so
we should reduce it.

OPW-2220893

closes odoo/odoo#49227

X-original-commit: 57999ea32c0cc85283faf06f6edb8649af784838
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
2020-04-08 12:39:17 +00:00
jvm-odoo 8c888caeab [FIX] sale: fix quantity input in SO template
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

closes odoo/odoo#48934

X-original-commit: 105a34accc6123cfb6be9738858499737df95613
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
2020-04-03 07:41:15 +00:00
jvm-odoo 1bfd21b6dc [FIX] sale, sale_management: fix mobile quantity input in SO template
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

closes odoo/odoo#48423

X-original-commit: 38e90e09239eb75bd25001c7870758b380159ad0
Signed-off-by: Jason Van Malder (jvm) <jvm@odoo.com>
2020-03-27 08:24:12 +00:00
Aaron Bohy 25aaf7afcf [FIX] sale,*: product_configurator: can drag&drop row
*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

closes odoo/odoo#48128

X-original-commit: d9c35b40b7df588f9e81142a2b272d9c7da06e04
Signed-off-by: Lucas Perais (lpe) <lpe@odoo.com>
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
2020-03-20 15:44:47 +00:00
Romeo Fragomeli ab2e3fdb7d [REF] *: add tour steps utils
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.
2020-03-11 10:10:16 +00:00
jvm-odoo bf1e8a89e7 [FIX] sale: fix SO no line break in note lines
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

closes odoo/odoo#47272

X-original-commit: af8fb786a9569562cefb7d8ea63454cddc04cd44
Signed-off-by: Jason Van Malder (jvm) <jvm@odoo.com>
2020-03-10 10:59:05 +00:00