Skip to content

Commit

Permalink
Merge pull request odoo#732 from odoo-dev/master-fix-website_sale-cha…
Browse files Browse the repository at this point in the history
…nge-price-chm

[FIX] website_sale: user can't edit the price.
  • Loading branch information
Gorash committed Jun 23, 2014
2 parents f2c2dee + 1d1b6e7 commit c81708a
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 5 deletions.
6 changes: 2 additions & 4 deletions addons/website_sale/static/src/js/website.tour.shop.js
Original file line number Diff line number Diff line change
Expand Up @@ -47,16 +47,14 @@
popover: { next: _t("Continue") },
},
{
element: '.product_price .oe_currency_value',
element: '.product_price .oe_currency_value:visible',
sampleText: '20.50',
placement: 'left',
title: _t("Change the price"),
content: _t("Edit the price of this product by clicking on the amount."),
},


{
waitNot: '.product_price .oe_currency_value:containsExact(1.00)',
waitNot: '.product_price .oe_currency_value:visible:containsExact(1.00)',
element: '#wrap img.product_detail_img',
placement: 'top',
title: _t("Update image"),
Expand Down
9 changes: 8 additions & 1 deletion addons/website_sale/views/templates.xml
Original file line number Diff line number Diff line change
Expand Up @@ -408,7 +408,7 @@

<template id="product_price">
<div itemprop="offers" itemscope="itemscope" itemtype="http://schema.org/Offer" class="product_price mt16">
<h4 class="oe_price_h4">
<h4 class="oe_price_h4 css_editable_mode_hidden">
<t t-if="product.lst_price != product.price">
<span class="text-danger" style="text-decoration: line-through;"
t-field="product.lst_price"
Expand All @@ -426,6 +426,13 @@
<span itemprop="price" style="display:none;" t-esc="product.price"/>
<span itemprop="priceCurrency" style="display:none;" t-esc="website.pricelist_id.currency_id.name"/>
</h4>
<h4 class="css_editable_mode_display" style="display: none;">
<span t-field="product.lst_price"
t-field-options='{
"widget": "monetary",
"display_currency": "website.pricelist_id.currency_id"
}'/>
</h4>
<h4 class="hidden oe_not_available bg-warning">Product not available</h4>
</div>
</template>
Expand Down

0 comments on commit c81708a

Please sign in to comment.