From 656fcad3eb3f1b2886a61eb33f7b2e5af16bb2a1 Mon Sep 17 00:00:00 2001 From: Fabien Pinckaers Date: Tue, 1 Oct 2013 00:51:05 +0200 Subject: [PATCH] [IMP] Payment Process Design bzr revid: fp@openerp.com-20130930225105-0dses1tdzm2iysfp --- addons/website_sale/controllers/main.py | 5 +- .../static/src/css/website_sale.css | 74 ++ .../static/src/css/website_sale.sass | 66 ++ addons/website_sale/views/website_sale.xml | 677 ++++++++++-------- 4 files changed, 509 insertions(+), 313 deletions(-) diff --git a/addons/website_sale/controllers/main.py b/addons/website_sale/controllers/main.py index 1d5db33967d..db6850588a7 100644 --- a/addons/website_sale/controllers/main.py +++ b/addons/website_sale/controllers/main.py @@ -395,6 +395,7 @@ class Ecommerce(http.Controller): suggested_products.append(suggested_ids.pop(index)) values = { + 'int': int, 'get_categories': self.get_categories, 'suggested_products': prod_obj.browse(request.cr, request.uid, suggested_products, request.context), } @@ -415,7 +416,7 @@ class Ecommerce(http.Controller): @website.route(['/shop/checkout/'], type='http', auth="public", multilang=True) def checkout(self, **post): - classic_fields = ["name", "phone", "fax", "email", "street", "city", "state_id", "zip"] + classic_fields = ["name", "phone", "email", "street", "city", "state_id", "zip"] rel_fields = ['country_id', 'state_id'] order = get_current_order() @@ -488,7 +489,6 @@ class Ecommerce(http.Controller): company_id = partner_obj.create(request.cr, SUPERUSER_ID, {'name': post['company'], 'is_company': True}, request.context) partner_value = { - 'fax': post['fax'], 'phone': post['phone'], 'zip': post['zip'], 'email': post['email'], @@ -508,7 +508,6 @@ class Ecommerce(http.Controller): shipping_id = None if post.get('shipping_different'): shipping_value = { - 'fax': post['shipping_fax'], 'phone': post['shipping_phone'], 'zip': post['shipping_zip'], 'street': post['shipping_street'], diff --git a/addons/website_sale/static/src/css/website_sale.css b/addons/website_sale/static/src/css/website_sale.css index f253f5badd9..d8c68f3e8cd 100644 --- a/addons/website_sale/static/src/css/website_sale.css +++ b/addons/website_sale/static/src/css/website_sale.css @@ -30,6 +30,11 @@ border-top: 1px solid #dddddd; } +.oe_mycart .input-group-addon { + padding-left: 6px; + padding-right: 6px; +} + .oe_shop_top .oe_product_description { top: 0; bottom: auto; @@ -128,6 +133,7 @@ display: none; } } + @media (min-width: 992px) { .col-md-12 .oe-height-1 { height: 95px; @@ -155,6 +161,7 @@ height: 288px; } } + @media (min-width: 1200px) { .col-md-12 .oe-height-1 { height: 125px; @@ -182,6 +189,7 @@ height: 380px; } } + /* ---- Product list style ---- */ .oe_list_products { border: none; @@ -284,3 +292,69 @@ -moz-box-shadow: 0px 0px 3px rgba(0, 0, 0, 0.3); box-shadow: 0px 0px 3px rgba(0, 0, 0, 0.3); } + +/* Wizard */ +ul.wizard { + padding: 0; + margin-top: 20px; + list-style: none outside none; + border: 1px solid #d4d4d4; + -webkit-border-radius: 4px; + -moz-border-radius: 4px; + border-radius: 4px; + -webkit-box-shadow: 0 1px 2px rgba(0, 0, 0, 0.065); + -moz-box-shadow: 0 1px 2px rgba(0, 0, 0, 0.065); + box-shadow: 0 1px 2px rgba(0, 0, 0, 0.065); +} + +ul.wizard li { + position: relative; + float: left; + padding: 0 10px 0 20px; + margin: 0; + line-height: 38px; + background: #fbfbfb; +} + +ul.wizard li .chevron { + position: absolute; + top: 0; + right: -10px; + z-index: 1; + display: block; + border: 20px solid transparent; + border-right: 0; + border-left: 10px solid #d4d4d4; +} + +ul.wizard li .chevron:before { + position: absolute; + top: -20px; + right: 1px; + display: block; + border: 20px solid transparent; + border-right: 0; + border-left: 10px solid #fbfbfb; + content: ""; +} + +ul.wizard li.text-success { + background: #f3f4f5; +} + +ul.wizard li.text-success .chevron:before { + border-left: 10px solid #f5f5f5; +} + +ul.wizard li.text-primary { + background: #f1f6fc; +} + +ul.wizard li.text-primary .chevron:before { + border-left: 10px solid #f1f6fc; +} + +ul.wizard li:first-child { + padding-left: 15px; + border-radius: 4px 0 0 4px; +} diff --git a/addons/website_sale/static/src/css/website_sale.sass b/addons/website_sale/static/src/css/website_sale.sass index 6edcdae16f3..d03e81c7e4d 100644 --- a/addons/website_sale/static/src/css/website_sale.sass +++ b/addons/website_sale/static/src/css/website_sale.sass @@ -29,6 +29,11 @@ right: 15px border-top: 1px solid #dddddd +.oe_mycart + .input-group-addon + padding-left: 6px + padding-right: 6px + .oe_shop_top /* Option 1 */ .oe_product_description @@ -250,3 +255,64 @@ -webkit-box-shadow: 0px 0px 3px rgba(0,0,0,0.3) -moz-box-shadow: 0px 0px 3px rgba(0,0,0,0.3) box-shadow: 0px 0px 3px rgba(0,0,0,0.3) + + +/* Wizard */ + + +ul.wizard + padding: 0 + margin-top: 20px + list-style: none outside none + border: 1px solid #d4d4d4 + -webkit-border-radius: 4px + -moz-border-radius: 4px + border-radius: 4px + -webkit-box-shadow: 0 1px 2px rgba(0, 0, 0, 0.065) + -moz-box-shadow: 0 1px 2px rgba(0, 0, 0, 0.065) + box-shadow: 0 1px 2px rgba(0, 0, 0, 0.065) + +ul.wizard li + position: relative + float: left + padding: 0 10px 0 20px + margin: 0 + line-height: 38px + background: #fbfbfb + +ul.wizard li .chevron + position: absolute + top: 0 + right: -10px + z-index: 1 + display: block + border: 20px solid transparent + border-right: 0 + border-left: 10px solid #d4d4d4 + +ul.wizard li .chevron:before + position: absolute + top: -20px + right: 1px + display: block + border: 20px solid transparent + border-right: 0 + border-left: 10px solid #fbfbfb + content: "" + +ul.wizard li.text-success + background: #f3f4f5 + +ul.wizard li.text-success .chevron:before + border-left: 10px solid #f5f5f5 + +ul.wizard li.text-primary + background: #f1f6fc + +ul.wizard li.text-primary .chevron:before + border-left: 10px solid #f1f6fc + +ul.wizard li:first-child + padding-left: 15px + border-radius: 4px 0 0 4px + diff --git a/addons/website_sale/views/website_sale.xml b/addons/website_sale/views/website_sale.xml index 5c2cb449e29..70d4ed8b622 100644 --- a/addons/website_sale/views/website_sale.xml +++ b/addons/website_sale/views/website_sale.xml @@ -379,19 +379,32 @@ + Your Cart
-
-

My Shopping Cart

- + +
    +
  • Review Order
  • +
  • Shipping & Billing
  • +
  • Payment
  • +
  • Confirmation
  • +
+

Your Cart

+ +
+
+
+ Your cart is empty! +
+
- - + + @@ -400,52 +413,84 @@ - - - - - - - - - - - - - + + + + + + + +
Quantity

Your cart is empty

- - -
- -
- - - - € - -
- - - - + -
-
+ + +
+ + + +
+
+
+ € +
+ € +
+
+
+ + + + + + + + + + + +
+ +
- +
- - - - + + - - - + + + + + + + +
Subtotal
Taxes

Total

Total:

Incl. Taxes:
- Proceed To Payment +
+ + Continue Shopping + Process Checkout +
+
+
+

Policies

+
    +
  • 30-days money-back guarantee
  • +
  • Invoice sent by e-Mail
  • +
+ +

Secure Payment

+
    +
  • Transation 256bit encrypted
  • +
  • Processed by Ogone
  • +
+ +
+
@@ -474,66 +519,59 @@ - + @@ -545,244 +583,263 @@ + Shop - Checkout
+
    +
  • Review Order
  • +
  • Shipping & Billing
  • +
  • Payment
  • +
  • Confirmation
  • +
+

Your Address

+
+
-
- - - - - - - - - - - - - - - - - - - - - - -
ProductPriceQty.
Untaxed Amount
Taxes
Total
+
+ +
+
+ + +
+
+ + +
+
+ + +
+
+ + +
+ +
+ + +
+
+ +
+ + +
+
+ + +
+
+ + +
+
+ + +
+ +
+ +
+ +
+
+ +
+

Shipping Information

+ +
+ + +
+
+ + +
+
+ + +
+
+
+ + +
+
+ + +
+
+ + +
+
+ + +
+
+ +
+
+ +
+
Subtotal:
+
+
Taxes:
+
+

Total To Pay:

+

- -
- Log me, I have an account -

Billing Information

-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
-
- -
-
-
-
-

Shipping Information

-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- - + +
+ +