spree_frontend 2.4.10 → 3.0.0.rc1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +1 -0
- data/Gemfile +6 -0
- data/LICENSE +1 -1
- data/README.md +39 -10
- data/Rakefile +29 -0
- data/{vendor → app}/assets/images/flags/ad.png +0 -0
- data/{vendor → app}/assets/images/flags/ae.png +0 -0
- data/{vendor → app}/assets/images/flags/af.png +0 -0
- data/{vendor → app}/assets/images/flags/ag.png +0 -0
- data/{vendor → app}/assets/images/flags/ai.png +0 -0
- data/{vendor → app}/assets/images/flags/al.png +0 -0
- data/{vendor → app}/assets/images/flags/am.png +0 -0
- data/{vendor → app}/assets/images/flags/an.png +0 -0
- data/{vendor → app}/assets/images/flags/ao.png +0 -0
- data/{vendor → app}/assets/images/flags/ar.png +0 -0
- data/{vendor → app}/assets/images/flags/as.png +0 -0
- data/{vendor → app}/assets/images/flags/at.png +0 -0
- data/{vendor → app}/assets/images/flags/au.png +0 -0
- data/{vendor → app}/assets/images/flags/aw.png +0 -0
- data/{vendor → app}/assets/images/flags/ax.png +0 -0
- data/{vendor → app}/assets/images/flags/az.png +0 -0
- data/{vendor → app}/assets/images/flags/ba.png +0 -0
- data/{vendor → app}/assets/images/flags/bb.png +0 -0
- data/{vendor → app}/assets/images/flags/bd.png +0 -0
- data/{vendor → app}/assets/images/flags/be.png +0 -0
- data/{vendor → app}/assets/images/flags/bf.png +0 -0
- data/{vendor → app}/assets/images/flags/bg.png +0 -0
- data/{vendor → app}/assets/images/flags/bh.png +0 -0
- data/{vendor → app}/assets/images/flags/bi.png +0 -0
- data/{vendor → app}/assets/images/flags/bj.png +0 -0
- data/{vendor → app}/assets/images/flags/bm.png +0 -0
- data/{vendor → app}/assets/images/flags/bn.png +0 -0
- data/{vendor → app}/assets/images/flags/bo.png +0 -0
- data/{vendor → app}/assets/images/flags/br.png +0 -0
- data/{vendor → app}/assets/images/flags/bs.png +0 -0
- data/{vendor → app}/assets/images/flags/bt.png +0 -0
- data/{vendor → app}/assets/images/flags/bv.png +0 -0
- data/{vendor → app}/assets/images/flags/bw.png +0 -0
- data/{vendor → app}/assets/images/flags/by.png +0 -0
- data/{vendor → app}/assets/images/flags/bz.png +0 -0
- data/{vendor → app}/assets/images/flags/ca.png +0 -0
- data/{vendor → app}/assets/images/flags/catalonia.png +0 -0
- data/{vendor → app}/assets/images/flags/cc.png +0 -0
- data/{vendor → app}/assets/images/flags/cd.png +0 -0
- data/{vendor → app}/assets/images/flags/cf.png +0 -0
- data/{vendor → app}/assets/images/flags/cg.png +0 -0
- data/{vendor → app}/assets/images/flags/ch.png +0 -0
- data/{vendor → app}/assets/images/flags/ci.png +0 -0
- data/{vendor → app}/assets/images/flags/ck.png +0 -0
- data/{vendor → app}/assets/images/flags/cl.png +0 -0
- data/{vendor → app}/assets/images/flags/cm.png +0 -0
- data/{vendor → app}/assets/images/flags/cn.png +0 -0
- data/{vendor → app}/assets/images/flags/co.png +0 -0
- data/{vendor → app}/assets/images/flags/cr.png +0 -0
- data/{vendor → app}/assets/images/flags/cs.png +0 -0
- data/{vendor → app}/assets/images/flags/cu.png +0 -0
- data/{vendor → app}/assets/images/flags/cv.png +0 -0
- data/{vendor → app}/assets/images/flags/cx.png +0 -0
- data/{vendor → app}/assets/images/flags/cy.png +0 -0
- data/{vendor → app}/assets/images/flags/cz.png +0 -0
- data/{vendor → app}/assets/images/flags/de.png +0 -0
- data/{vendor → app}/assets/images/flags/dj.png +0 -0
- data/{vendor → app}/assets/images/flags/dk.png +0 -0
- data/{vendor → app}/assets/images/flags/dm.png +0 -0
- data/{vendor → app}/assets/images/flags/do.png +0 -0
- data/{vendor → app}/assets/images/flags/dz.png +0 -0
- data/{vendor → app}/assets/images/flags/ec.png +0 -0
- data/{vendor → app}/assets/images/flags/ee.png +0 -0
- data/{vendor → app}/assets/images/flags/eg.png +0 -0
- data/{vendor → app}/assets/images/flags/eh.png +0 -0
- data/{vendor → app}/assets/images/flags/england.png +0 -0
- data/{vendor → app}/assets/images/flags/er.png +0 -0
- data/{vendor → app}/assets/images/flags/es.png +0 -0
- data/{vendor → app}/assets/images/flags/et.png +0 -0
- data/{vendor → app}/assets/images/flags/europeanunion.png +0 -0
- data/{vendor → app}/assets/images/flags/fam.png +0 -0
- data/{vendor → app}/assets/images/flags/fi.png +0 -0
- data/{vendor → app}/assets/images/flags/fj.png +0 -0
- data/{vendor → app}/assets/images/flags/fk.png +0 -0
- data/{vendor → app}/assets/images/flags/fm.png +0 -0
- data/{vendor → app}/assets/images/flags/fo.png +0 -0
- data/{vendor → app}/assets/images/flags/fr.png +0 -0
- data/{vendor → app}/assets/images/flags/ga.png +0 -0
- data/{vendor → app}/assets/images/flags/gb.png +0 -0
- data/{vendor → app}/assets/images/flags/gd.png +0 -0
- data/{vendor → app}/assets/images/flags/ge.png +0 -0
- data/{vendor → app}/assets/images/flags/gf.png +0 -0
- data/{vendor → app}/assets/images/flags/gh.png +0 -0
- data/{vendor → app}/assets/images/flags/gi.png +0 -0
- data/{vendor → app}/assets/images/flags/gl.png +0 -0
- data/{vendor → app}/assets/images/flags/gm.png +0 -0
- data/{vendor → app}/assets/images/flags/gn.png +0 -0
- data/{vendor → app}/assets/images/flags/gp.png +0 -0
- data/{vendor → app}/assets/images/flags/gq.png +0 -0
- data/{vendor → app}/assets/images/flags/gr.png +0 -0
- data/{vendor → app}/assets/images/flags/gs.png +0 -0
- data/{vendor → app}/assets/images/flags/gt.png +0 -0
- data/{vendor → app}/assets/images/flags/gu.png +0 -0
- data/{vendor → app}/assets/images/flags/gw.png +0 -0
- data/{vendor → app}/assets/images/flags/gy.png +0 -0
- data/{vendor → app}/assets/images/flags/hk.png +0 -0
- data/{vendor → app}/assets/images/flags/hm.png +0 -0
- data/{vendor → app}/assets/images/flags/hn.png +0 -0
- data/{vendor → app}/assets/images/flags/hr.png +0 -0
- data/{vendor → app}/assets/images/flags/ht.png +0 -0
- data/{vendor → app}/assets/images/flags/hu.png +0 -0
- data/{vendor → app}/assets/images/flags/id.png +0 -0
- data/{vendor → app}/assets/images/flags/ie.png +0 -0
- data/{vendor → app}/assets/images/flags/il.png +0 -0
- data/{vendor → app}/assets/images/flags/in.png +0 -0
- data/{vendor → app}/assets/images/flags/io.png +0 -0
- data/{vendor → app}/assets/images/flags/iq.png +0 -0
- data/{vendor → app}/assets/images/flags/ir.png +0 -0
- data/{vendor → app}/assets/images/flags/is.png +0 -0
- data/{vendor → app}/assets/images/flags/it.png +0 -0
- data/{vendor → app}/assets/images/flags/ja.png +0 -0
- data/{vendor → app}/assets/images/flags/jm.png +0 -0
- data/{vendor → app}/assets/images/flags/jo.png +0 -0
- data/{vendor → app}/assets/images/flags/ke.png +0 -0
- data/{vendor → app}/assets/images/flags/kg.png +0 -0
- data/{vendor → app}/assets/images/flags/kh.png +0 -0
- data/{vendor → app}/assets/images/flags/ki.png +0 -0
- data/{vendor → app}/assets/images/flags/km.png +0 -0
- data/{vendor → app}/assets/images/flags/kn.png +0 -0
- data/{vendor → app}/assets/images/flags/kp.png +0 -0
- data/{vendor → app}/assets/images/flags/kr.png +0 -0
- data/{vendor → app}/assets/images/flags/kw.png +0 -0
- data/{vendor → app}/assets/images/flags/ky.png +0 -0
- data/{vendor → app}/assets/images/flags/kz.png +0 -0
- data/{vendor → app}/assets/images/flags/la.png +0 -0
- data/{vendor → app}/assets/images/flags/lb.png +0 -0
- data/{vendor → app}/assets/images/flags/lc.png +0 -0
- data/{vendor → app}/assets/images/flags/li.png +0 -0
- data/{vendor → app}/assets/images/flags/lk.png +0 -0
- data/{vendor → app}/assets/images/flags/lr.png +0 -0
- data/{vendor → app}/assets/images/flags/ls.png +0 -0
- data/{vendor → app}/assets/images/flags/lt.png +0 -0
- data/{vendor → app}/assets/images/flags/lu.png +0 -0
- data/{vendor → app}/assets/images/flags/lv.png +0 -0
- data/{vendor → app}/assets/images/flags/ly.png +0 -0
- data/{vendor → app}/assets/images/flags/ma.png +0 -0
- data/{vendor → app}/assets/images/flags/mc.png +0 -0
- data/{vendor → app}/assets/images/flags/md.png +0 -0
- data/{vendor → app}/assets/images/flags/me.png +0 -0
- data/{vendor → app}/assets/images/flags/mg.png +0 -0
- data/{vendor → app}/assets/images/flags/mh.png +0 -0
- data/{vendor → app}/assets/images/flags/mk.png +0 -0
- data/{vendor → app}/assets/images/flags/ml.png +0 -0
- data/{vendor → app}/assets/images/flags/mm.png +0 -0
- data/{vendor → app}/assets/images/flags/mn.png +0 -0
- data/{vendor → app}/assets/images/flags/mo.png +0 -0
- data/{vendor → app}/assets/images/flags/mp.png +0 -0
- data/{vendor → app}/assets/images/flags/mq.png +0 -0
- data/{vendor → app}/assets/images/flags/mr.png +0 -0
- data/{vendor → app}/assets/images/flags/ms.png +0 -0
- data/{vendor → app}/assets/images/flags/mt.png +0 -0
- data/{vendor → app}/assets/images/flags/mu.png +0 -0
- data/{vendor → app}/assets/images/flags/mv.png +0 -0
- data/{vendor → app}/assets/images/flags/mw.png +0 -0
- data/{vendor → app}/assets/images/flags/mx.png +0 -0
- data/{vendor → app}/assets/images/flags/my.png +0 -0
- data/{vendor → app}/assets/images/flags/mz.png +0 -0
- data/{vendor → app}/assets/images/flags/na.png +0 -0
- data/{vendor → app}/assets/images/flags/nc.png +0 -0
- data/{vendor → app}/assets/images/flags/ne.png +0 -0
- data/{vendor → app}/assets/images/flags/nf.png +0 -0
- data/{vendor → app}/assets/images/flags/ng.png +0 -0
- data/{vendor → app}/assets/images/flags/ni.png +0 -0
- data/{vendor → app}/assets/images/flags/nl.png +0 -0
- data/{vendor → app}/assets/images/flags/no.png +0 -0
- data/{vendor → app}/assets/images/flags/np.png +0 -0
- data/{vendor → app}/assets/images/flags/nr.png +0 -0
- data/{vendor → app}/assets/images/flags/nu.png +0 -0
- data/{vendor → app}/assets/images/flags/nz.png +0 -0
- data/{vendor → app}/assets/images/flags/om.png +0 -0
- data/{vendor → app}/assets/images/flags/pa.png +0 -0
- data/{vendor → app}/assets/images/flags/pe.png +0 -0
- data/{vendor → app}/assets/images/flags/pf.png +0 -0
- data/{vendor → app}/assets/images/flags/pg.png +0 -0
- data/{vendor → app}/assets/images/flags/ph.png +0 -0
- data/{vendor → app}/assets/images/flags/pk.png +0 -0
- data/{vendor → app}/assets/images/flags/pl.png +0 -0
- data/{vendor → app}/assets/images/flags/pm.png +0 -0
- data/{vendor → app}/assets/images/flags/pn.png +0 -0
- data/{vendor → app}/assets/images/flags/pr.png +0 -0
- data/{vendor → app}/assets/images/flags/ps.png +0 -0
- data/{vendor → app}/assets/images/flags/pt.png +0 -0
- data/{vendor → app}/assets/images/flags/pw.png +0 -0
- data/{vendor → app}/assets/images/flags/py.png +0 -0
- data/{vendor → app}/assets/images/flags/qa.png +0 -0
- data/{vendor → app}/assets/images/flags/re.png +0 -0
- data/{vendor → app}/assets/images/flags/ro.png +0 -0
- data/{vendor → app}/assets/images/flags/rs.png +0 -0
- data/{vendor → app}/assets/images/flags/ru.png +0 -0
- data/{vendor → app}/assets/images/flags/rw.png +0 -0
- data/{vendor → app}/assets/images/flags/sa.png +0 -0
- data/{vendor → app}/assets/images/flags/sb.png +0 -0
- data/{vendor → app}/assets/images/flags/sc.png +0 -0
- data/{vendor → app}/assets/images/flags/scotland.png +0 -0
- data/{vendor → app}/assets/images/flags/sd.png +0 -0
- data/{vendor → app}/assets/images/flags/se.png +0 -0
- data/{vendor → app}/assets/images/flags/sg.png +0 -0
- data/{vendor → app}/assets/images/flags/sh.png +0 -0
- data/{vendor → app}/assets/images/flags/si.png +0 -0
- data/{vendor → app}/assets/images/flags/sj.png +0 -0
- data/{vendor → app}/assets/images/flags/sk.png +0 -0
- data/{vendor → app}/assets/images/flags/sl.png +0 -0
- data/{vendor → app}/assets/images/flags/sm.png +0 -0
- data/{vendor → app}/assets/images/flags/sn.png +0 -0
- data/{vendor → app}/assets/images/flags/so.png +0 -0
- data/{vendor → app}/assets/images/flags/sr.png +0 -0
- data/{vendor → app}/assets/images/flags/st.png +0 -0
- data/{vendor → app}/assets/images/flags/sv.png +0 -0
- data/{vendor → app}/assets/images/flags/sy.png +0 -0
- data/{vendor → app}/assets/images/flags/sz.png +0 -0
- data/{vendor → app}/assets/images/flags/tc.png +0 -0
- data/{vendor → app}/assets/images/flags/td.png +0 -0
- data/{vendor → app}/assets/images/flags/tf.png +0 -0
- data/{vendor → app}/assets/images/flags/tg.png +0 -0
- data/{vendor → app}/assets/images/flags/th.png +0 -0
- data/{vendor → app}/assets/images/flags/tj.png +0 -0
- data/{vendor → app}/assets/images/flags/tk.png +0 -0
- data/{vendor → app}/assets/images/flags/tl.png +0 -0
- data/{vendor → app}/assets/images/flags/tm.png +0 -0
- data/{vendor → app}/assets/images/flags/tn.png +0 -0
- data/{vendor → app}/assets/images/flags/to.png +0 -0
- data/{vendor → app}/assets/images/flags/tr.png +0 -0
- data/{vendor → app}/assets/images/flags/tt.png +0 -0
- data/{vendor → app}/assets/images/flags/tv.png +0 -0
- data/{vendor → app}/assets/images/flags/tw.png +0 -0
- data/{vendor → app}/assets/images/flags/tz.png +0 -0
- data/{vendor → app}/assets/images/flags/ua.png +0 -0
- data/{vendor → app}/assets/images/flags/ug.png +0 -0
- data/{vendor → app}/assets/images/flags/um.png +0 -0
- data/{vendor → app}/assets/images/flags/us.png +0 -0
- data/{vendor → app}/assets/images/flags/uy.png +0 -0
- data/{vendor → app}/assets/images/flags/uz.png +0 -0
- data/{vendor → app}/assets/images/flags/va.png +0 -0
- data/{vendor → app}/assets/images/flags/vc.png +0 -0
- data/{vendor → app}/assets/images/flags/ve.png +0 -0
- data/{vendor → app}/assets/images/flags/vg.png +0 -0
- data/{vendor → app}/assets/images/flags/vi.png +0 -0
- data/{vendor → app}/assets/images/flags/vn.png +0 -0
- data/{vendor → app}/assets/images/flags/vu.png +0 -0
- data/{vendor → app}/assets/images/flags/wales.png +0 -0
- data/{vendor → app}/assets/images/flags/wf.png +0 -0
- data/{vendor → app}/assets/images/flags/ws.png +0 -0
- data/{vendor → app}/assets/images/flags/ye.png +0 -0
- data/{vendor → app}/assets/images/flags/yt.png +0 -0
- data/{vendor → app}/assets/images/flags/za.png +0 -0
- data/{vendor → app}/assets/images/flags/zm.png +0 -0
- data/{vendor → app}/assets/images/flags/zw.png +0 -0
- data/app/assets/images/logo/spree_50.png +0 -0
- data/app/assets/images/spree_header.jpg +0 -0
- data/app/assets/javascripts/spree/frontend.js +1 -1
- data/app/assets/javascripts/spree/frontend/checkout/payment.js.coffee +2 -2
- data/app/assets/stylesheets/spree/frontend.css +4 -4
- data/app/assets/stylesheets/spree/frontend/_variables.scss +4 -61
- data/app/assets/stylesheets/spree/frontend/frontend_bootstrap.css.scss +102 -0
- data/app/controllers/spree/checkout_controller.rb +31 -27
- data/app/controllers/spree/orders_controller.rb +20 -8
- data/app/controllers/spree/store_controller.rb +2 -3
- data/app/controllers/spree/taxons_controller.rb +2 -2
- data/app/helpers/spree/frontend_helper.rb +93 -0
- data/app/helpers/spree/orders_helper.rb +16 -0
- data/app/helpers/spree/store_helper.rb +10 -0
- data/app/helpers/spree/taxons_helper.rb +19 -0
- data/app/models/spree/frontend_configuration.rb +1 -1
- data/app/views/kaminari/twitter-bootstrap-3/_first_page.html.erb +13 -0
- data/app/views/kaminari/twitter-bootstrap-3/_gap.html.erb +8 -0
- data/app/views/kaminari/twitter-bootstrap-3/_last_page.html.erb +13 -0
- data/app/views/kaminari/twitter-bootstrap-3/_next_page.html.erb +13 -0
- data/app/views/kaminari/twitter-bootstrap-3/_page.html.erb +12 -0
- data/app/views/kaminari/twitter-bootstrap-3/_paginator.html.erb +24 -0
- data/app/views/kaminari/twitter-bootstrap-3/_prev_page.html.erb +13 -0
- data/app/views/spree/address/_form.html.erb +24 -24
- data/app/views/spree/checkout/_address.html.erb +33 -22
- data/app/views/spree/checkout/_confirm.html.erb +10 -9
- data/app/views/spree/checkout/_delivery.html.erb +24 -20
- data/app/views/spree/checkout/_payment.html.erb +17 -18
- data/app/views/spree/checkout/_summary.html.erb +2 -2
- data/app/views/spree/checkout/edit.html.erb +23 -14
- data/app/views/spree/checkout/payment/_gateway.html.erb +31 -28
- data/app/views/spree/layouts/spree_application.html.erb +6 -12
- data/app/views/spree/orders/_adjustments.html.erb +5 -0
- data/app/views/spree/orders/_form.html.erb +8 -8
- data/app/views/spree/orders/_line_item.html.erb +6 -6
- data/app/views/spree/orders/edit.html.erb +14 -16
- data/app/views/spree/orders/show.html.erb +9 -4
- data/app/views/spree/products/_cart_form.html.erb +15 -11
- data/app/views/spree/products/_promotions.html.erb +1 -1
- data/app/views/spree/products/_properties.html.erb +2 -2
- data/app/views/spree/products/_taxons.html.erb +4 -4
- data/app/views/spree/products/_thumbnails.html.erb +3 -3
- data/app/views/spree/products/index.html.erb +13 -9
- data/app/views/spree/products/show.html.erb +11 -9
- data/app/views/spree/shared/_error_messages.html.erb +12 -0
- data/app/views/spree/shared/_filters.html.erb +4 -4
- data/app/views/spree/shared/_footer.html.erb +10 -6
- data/app/views/spree/shared/_google_add_items.js.erb +11 -0
- data/app/views/spree/shared/_google_analytics.js.erb +13 -0
- data/app/views/spree/shared/_google_checkout.js.erb +10 -0
- data/app/views/spree/shared/_google_purchase.js.erb +13 -0
- data/app/views/spree/shared/_head.html.erb +1 -1
- data/app/views/spree/shared/_header.html.erb +17 -5
- data/app/views/spree/shared/_login.html.erb +19 -0
- data/app/views/spree/shared/_login_bar.html.erb +6 -0
- data/app/views/spree/shared/_main_nav_bar.html.erb +15 -11
- data/app/views/spree/shared/_nav_bar.html.erb +3 -2
- data/app/views/spree/shared/_order_details.html.erb +30 -31
- data/app/views/spree/shared/_products.html.erb +19 -15
- data/app/views/spree/shared/_search.html.erb +8 -4
- data/app/views/spree/shared/_sidebar.html.erb +1 -1
- data/app/views/spree/shared/_taxonomies.html.erb +1 -1
- data/app/views/spree/taxons/show.html.erb +1 -1
- data/config/initializers/spree.rb +0 -2
- data/lib/spree/frontend.rb +5 -4
- data/lib/spree/frontend/engine.rb +2 -2
- data/script/rails +9 -0
- data/spec/controllers/controller_extension_spec.rb +115 -0
- data/spec/controllers/controller_helpers_spec.rb +26 -0
- data/spec/controllers/spree/checkout_controller_spec.rb +424 -0
- data/spec/controllers/spree/checkout_controller_with_views_spec.rb +36 -0
- data/spec/controllers/spree/content_controller_spec.rb +12 -0
- data/spec/controllers/spree/current_order_tracking_spec.rb +44 -0
- data/spec/controllers/spree/home_controller_spec.rb +27 -0
- data/spec/controllers/spree/orders_controller_ability_spec.rb +104 -0
- data/spec/controllers/spree/orders_controller_spec.rb +134 -0
- data/spec/controllers/spree/orders_controller_transitions_spec.rb +31 -0
- data/spec/controllers/spree/products_controller_spec.rb +36 -0
- data/spec/controllers/spree/taxons_controller_spec.rb +12 -0
- data/spec/features/address_spec.rb +93 -0
- data/spec/features/automatic_promotion_adjustments_spec.rb +47 -0
- data/spec/features/caching/products_spec.rb +55 -0
- data/spec/features/caching/taxons_spec.rb +22 -0
- data/spec/features/cart_spec.rb +84 -0
- data/spec/features/checkout_spec.rb +515 -0
- data/spec/features/checkout_unshippable_spec.rb +34 -0
- data/spec/features/coupon_code_spec.rb +87 -0
- data/spec/features/currency_spec.rb +18 -0
- data/spec/features/free_shipping_promotions_spec.rb +59 -0
- data/spec/features/locale_spec.rb +60 -0
- data/spec/features/order_spec.rb +74 -0
- data/spec/features/page_promotions_spec.rb +36 -0
- data/spec/features/products_spec.rb +262 -0
- data/spec/features/taxons_spec.rb +147 -0
- data/spec/features/template_rendering_spec.rb +19 -0
- data/spec/fixtures/thinking-cat.jpg +0 -0
- data/spec/helpers/frontend_helper_spec.rb +41 -0
- data/spec/helpers/order_helper_spec.rb +12 -0
- data/spec/helpers/taxons_helper_spec.rb +17 -0
- data/spec/spec_helper.rb +115 -0
- data/spec/support/shared_contexts/checkout_setup.rb +9 -0
- data/spec/support/shared_contexts/custom_products.rb +25 -0
- data/spec/support/shared_contexts/product_prototypes.rb +30 -0
- data/spec/views/spree/checkout/_summary_spec.rb +11 -0
- data/spree_frontend.gemspec +30 -0
- metadata +392 -282
- data/app/assets/images/icons/add-to-cart.png +0 -0
- data/app/assets/images/icons/checkout.png +0 -0
- data/app/assets/images/icons/delete.png +0 -0
- data/app/assets/images/icons/update.png +0 -0
- data/app/assets/images/spinner.gif +0 -0
- data/app/assets/images/spree/frontend/cart.png +0 -0
- data/app/assets/images/spree/frontend/select_arrow.gif +0 -0
- data/app/assets/stylesheets/spree/frontend/screen.css.scss +0 -1321
- data/app/views/spree/shared/_google_analytics.html.erb +0 -40
- data/config/initializers/assets.rb +0 -1
- data/config/initializers/check_for_orphaned_preferences.rb +0 -9
- data/config/initializers/deprecation_checker.rb +0 -7
- data/config/initializers/rails_5868.rb +0 -8
- data/lib/spree/frontend/preference_rescue.rb +0 -25
- data/vendor/assets/images/datepicker/cal.gif +0 -0
- data/vendor/assets/images/jquery.formalize/button.png +0 -0
- data/vendor/assets/images/jquery.formalize/select_arrow.gif +0 -0
- data/vendor/assets/javascripts/jquery.formalize.min.js +0 -1
- data/vendor/assets/stylesheets/jquery.formalize.css.erb +0 -363
@@ -1,12 +1,13 @@
|
|
1
|
-
<
|
2
|
-
<div class="
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
1
|
+
<div class="panel panel-default" id="order_details" data-hook>
|
2
|
+
<div class="panel-heading">
|
3
|
+
<h3 class="panel-title"><%= Spree.t(:confirm) %></h3>
|
4
|
+
</div>
|
5
|
+
<div class="panel-body">
|
6
|
+
<%= render :partial => 'spree/shared/order_details', :locals => { :order => @order } %>
|
7
|
+
</div>
|
8
|
+
</div>
|
8
9
|
|
9
|
-
<div class="form-buttons" data-hook="buttons">
|
10
|
-
<%= submit_tag Spree.t(:place_order), :class => '
|
10
|
+
<div class="well text-right form-buttons" data-hook="buttons">
|
11
|
+
<%= submit_tag Spree.t(:place_order), :class => 'btn btn-lg btn-success' %>
|
11
12
|
<script>Spree.disableSaveOnClick();</script>
|
12
13
|
</div>
|
@@ -1,16 +1,18 @@
|
|
1
|
-
<
|
2
|
-
<
|
3
|
-
|
1
|
+
<div class="panel panel-default" id='shipping_method' data-hook>
|
2
|
+
<div class="panel-heading">
|
3
|
+
<h3 class="panel-title"><%= Spree.t(:delivery) %></h3>
|
4
|
+
</div>
|
5
|
+
<div class="panel-body" data-hook="shipping_method_inner">
|
4
6
|
<div id="methods">
|
5
7
|
<%= form.fields_for :shipments do |ship_form| %>
|
6
8
|
|
7
9
|
<div class="shipment">
|
8
|
-
<
|
10
|
+
<h4 class="stock-location" data-hook="stock-location">
|
9
11
|
<%= Spree.t(:package_from) %>
|
10
12
|
<strong class="stock-location-name" data-hook="stock-location-name"><%= ship_form.object.stock_location.name %></strong>
|
11
|
-
</
|
13
|
+
</h4>
|
12
14
|
|
13
|
-
<table class="stock-contents" data-hook="stock-contents">
|
15
|
+
<table class="table stock-contents" data-hook="stock-contents">
|
14
16
|
<colgroup>
|
15
17
|
<col style="width: 10%;" />
|
16
18
|
<col style="width: 60%;" />
|
@@ -18,10 +20,12 @@
|
|
18
20
|
<col style="width: 20%;" />
|
19
21
|
</colgroup>
|
20
22
|
<thead>
|
21
|
-
<
|
22
|
-
|
23
|
-
|
24
|
-
|
23
|
+
<tr class="active">
|
24
|
+
<th></th>
|
25
|
+
<th align='left'><%= Spree.t(:item) %></th>
|
26
|
+
<th><%= Spree.t(:qty) %></th>
|
27
|
+
<th><%= Spree.t(:price) %></th>
|
28
|
+
</tr>
|
25
29
|
</thead>
|
26
30
|
<tbody>
|
27
31
|
<% ship_form.object.manifest.each do |item| %>
|
@@ -35,14 +39,14 @@
|
|
35
39
|
</tbody>
|
36
40
|
</table>
|
37
41
|
|
38
|
-
<
|
39
|
-
<ul class="
|
42
|
+
<h4 class="stock-shipping-method-title"><%= Spree.t(:shipping_method) %></h4>
|
43
|
+
<ul class="list-group shipping-methods">
|
40
44
|
<% ship_form.object.shipping_rates.each do |rate| %>
|
41
|
-
<li class="shipping-method">
|
45
|
+
<li class="list-group-item shipping-method">
|
42
46
|
<label>
|
43
47
|
<%= ship_form.radio_button :selected_shipping_rate_id, rate.id %>
|
44
48
|
<span class="rate-name"><%= rate.name %></span>
|
45
|
-
<span class="rate-cost"><%= rate.display_cost %></span>
|
49
|
+
<span class="badge rate-cost"><%= rate.display_cost %></span>
|
46
50
|
</label>
|
47
51
|
</li>
|
48
52
|
<% end %>
|
@@ -56,7 +60,7 @@
|
|
56
60
|
<h3 class="stock-location" data-hook="stock-location">
|
57
61
|
<%= Spree.t(:unshippable_items) %>
|
58
62
|
</h3>
|
59
|
-
<table class="stock-contents" data-hook="stock-missing">
|
63
|
+
<table class="table stock-contents" data-hook="stock-missing">
|
60
64
|
<colgroup>
|
61
65
|
<col style="width: 10%;" />
|
62
66
|
<col style="width: 60%;" />
|
@@ -86,15 +90,15 @@
|
|
86
90
|
</div>
|
87
91
|
<% if Spree::Config[:shipping_instructions] %>
|
88
92
|
<p id="minstrs" data-hook>
|
89
|
-
|
90
|
-
<%= form.text_area :special_instructions, :cols => 40, :rows =>
|
93
|
+
<h4><%= Spree.t(:shipping_instructions) %></h4>
|
94
|
+
<%= form.text_area :special_instructions, :cols => 40, :rows => 4, :class => "form-control" %>
|
91
95
|
</p>
|
92
96
|
<% end %>
|
93
97
|
</div>
|
94
|
-
</
|
98
|
+
</div>
|
95
99
|
|
96
100
|
<br />
|
97
101
|
|
98
|
-
<div class="form-buttons" data-hook="buttons">
|
99
|
-
<%= submit_tag Spree.t(:save_and_continue), :class => '
|
102
|
+
<div class="well text-right form-buttons" data-hook="buttons">
|
103
|
+
<%= submit_tag Spree.t(:save_and_continue), :class => 'btn btn-lg btn-success' %>
|
100
104
|
</div>
|
@@ -1,6 +1,8 @@
|
|
1
|
-
<
|
2
|
-
<
|
3
|
-
|
1
|
+
<div class="panel panel-default" id="payment" data-hook>
|
2
|
+
<div class="panel-heading">
|
3
|
+
<h3 class="panel-title"><%= Spree.t(:payment_information) %></h3>
|
4
|
+
</div>
|
5
|
+
<div class="panel-body" data-hook="checkout_payment_step">
|
4
6
|
|
5
7
|
<% if @payment_sources.present? %>
|
6
8
|
<div class="card_options">
|
@@ -16,15 +18,14 @@
|
|
16
18
|
</div>
|
17
19
|
|
18
20
|
<div id="existing_cards">
|
19
|
-
<p class="
|
21
|
+
<p class="form-group" data-hook="existing_cards">
|
20
22
|
<table class="existing-credit-card-list">
|
21
23
|
<tbody>
|
22
24
|
<% @payment_sources.each do |card| %>
|
23
25
|
<tr id="<%= dom_id(card,'spree')%>" class="<%= cycle('even', 'odd') %>">
|
24
26
|
<td><%= card.name %></td>
|
25
27
|
<td><%= card.display_number %></td>
|
26
|
-
<td><%= card.month %></td>
|
27
|
-
<td><%= card.year %></td>
|
28
|
+
<td><%= card.month %> / <%= card.year %></td>
|
28
29
|
<td>
|
29
30
|
<%= radio_button_tag "order[existing_card]", card.id, (card == @payment_sources.first), { class: "existing-cc-radio" } %>
|
30
31
|
</td>
|
@@ -36,18 +37,18 @@
|
|
36
37
|
</div>
|
37
38
|
<% end %>
|
38
39
|
|
39
|
-
<
|
40
|
+
<ul class="list-group" id="payment-method-fields" data-hook>
|
40
41
|
<% @order.available_payment_methods.each do |method| %>
|
41
|
-
<
|
42
|
+
<li class="list-group-item">
|
42
43
|
<label>
|
43
44
|
<%= radio_button_tag "order[payments_attributes][][payment_method_id]", method.id, method == @order.available_payment_methods.first %>
|
44
45
|
<%= Spree.t(method.name, :scope => :payment_methods, :default => method.name) %>
|
45
46
|
</label>
|
46
|
-
</
|
47
|
+
</li>
|
47
48
|
<% end %>
|
48
|
-
</
|
49
|
+
</ul>
|
49
50
|
|
50
|
-
<ul id="payment-methods" data-hook>
|
51
|
+
<ul class="nav" id="payment-methods" data-hook>
|
51
52
|
<% @order.available_payment_methods.each do |method| %>
|
52
53
|
<li id="payment_method_<%= method.id %>" class="<%= 'last' if method == @order.available_payment_methods.last %>" data-hook>
|
53
54
|
<fieldset>
|
@@ -56,17 +57,15 @@
|
|
56
57
|
</li>
|
57
58
|
<% end %>
|
58
59
|
</ul>
|
59
|
-
|
60
|
+
|
60
61
|
<p class='field' data-hook='coupon_code'>
|
61
62
|
<%= form.label :coupon_code %><br />
|
62
|
-
<%= form.text_field :coupon_code %>
|
63
|
+
<%= form.text_field :coupon_code, :class => 'form-control' %>
|
63
64
|
</p>
|
64
65
|
</div>
|
65
|
-
</
|
66
|
-
|
67
|
-
<br class="space" />
|
66
|
+
</div>
|
68
67
|
|
69
|
-
<div class="form-buttons" data-hook="buttons">
|
70
|
-
<%= submit_tag Spree.t(:save_and_continue), :
|
68
|
+
<div class="well text-right form-buttons" data-hook="buttons">
|
69
|
+
<%= submit_tag Spree.t(:save_and_continue), class: 'btn btn-lg btn-success primary' %>
|
71
70
|
<script>Spree.disableSaveOnClick();</script>
|
72
71
|
</div>
|
@@ -1,6 +1,6 @@
|
|
1
1
|
<h3><%= Spree.t(:order_summary) %></h3>
|
2
2
|
|
3
|
-
<table data-hook="order_summary">
|
3
|
+
<table class="table" data-hook="order_summary">
|
4
4
|
<tbody>
|
5
5
|
<tr data-hook="item_total">
|
6
6
|
<td><strong><%= Spree.t(:item_total) %>:</strong></td>
|
@@ -59,7 +59,7 @@
|
|
59
59
|
|
60
60
|
<tr data-hook="order_total">
|
61
61
|
<td><strong><%= Spree.t(:order_total) %>:</strong></td>
|
62
|
-
<td><strong><span id='summary-order-total'><%= order.display_total.to_html %></span></strong></td>
|
62
|
+
<td><strong><span id='summary-order-total' class="lead text-primary"><%= order.display_total.to_html %></span></strong></td>
|
63
63
|
</tr>
|
64
64
|
</tbody>
|
65
65
|
</table>
|
@@ -1,35 +1,44 @@
|
|
1
|
+
<% content_for :google_analytics do %>
|
2
|
+
<%= render partial: 'spree/shared/google_checkout.js', locals: { order: @order, step_number: (@order.checkout_steps.index(@order.state) + 1) } %>
|
3
|
+
<% end %>
|
1
4
|
<div id="checkout" data-hook>
|
2
|
-
<%= render :
|
5
|
+
<%= render partial: 'spree/shared/error_messages', locals: { target: @order } %>
|
3
6
|
|
4
7
|
<div class="row" data-hook="checkout_header">
|
5
|
-
<
|
6
|
-
|
8
|
+
<div class="col-sm-3">
|
9
|
+
<h1 data-hook="checkout_title"><%= Spree.t(:checkout) %></h1>
|
10
|
+
</div>
|
11
|
+
<div class="col-sm-9" data-hook="checkout_progress"><%= checkout_progress %></div>
|
7
12
|
</div>
|
8
13
|
|
9
14
|
<div class="row" data-hook="checkout_content">
|
10
|
-
<div class="
|
11
|
-
<%= form_for @order, :
|
15
|
+
<div class="<%= if @order.state != 'confirm' then 'col-md-9' else 'col-md-12' end %>" data-hook="checkout_form_wrapper">
|
16
|
+
<%= form_for @order, url: update_checkout_path(@order.state), html: { id: "checkout_form_#{@order.state}" } do |form| %>
|
12
17
|
<% if @order.state == 'address' || !@order.email? %>
|
13
|
-
<
|
14
|
-
|
15
|
-
|
16
|
-
|
18
|
+
<div class="panel panel-default">
|
19
|
+
<div class="panel-body">
|
20
|
+
<div class="form-group">
|
21
|
+
<%= form.label :email %>
|
22
|
+
<%= form.text_field :email, class: 'form-control' %>
|
23
|
+
</div>
|
24
|
+
</div>
|
25
|
+
</div>
|
17
26
|
<% end %>
|
18
27
|
<%= form.hidden_field :state_lock_version %>
|
19
|
-
<%= render @order.state, :
|
28
|
+
<%= render @order.state, form: form %>
|
20
29
|
<% end %>
|
21
30
|
</div>
|
22
31
|
<% if @order.state != 'confirm' %>
|
23
|
-
<div id="checkout-summary" data-hook="checkout_summary_box" class="
|
24
|
-
<%= render :
|
32
|
+
<div id="checkout-summary" data-hook="checkout_summary_box" class="col-md-3">
|
33
|
+
<%= render partial: 'summary', locals: { order: @order } %>
|
25
34
|
</div>
|
26
35
|
<% end %>
|
27
36
|
</div>
|
28
37
|
</div>
|
29
38
|
|
30
39
|
<script>
|
31
|
-
Spree.current_order_id = "<%= @order.number %>"
|
32
|
-
Spree.current_order_token = "<%= @order.guest_token %>"
|
40
|
+
Spree.current_order_id = "<%= @order.number %>"
|
41
|
+
Spree.current_order_token = "<%= @order.guest_token %>"
|
33
42
|
</script>
|
34
43
|
|
35
44
|
<% if I18n.locale != :en %>
|
@@ -1,32 +1,35 @@
|
|
1
|
-
|
2
|
-
|
1
|
+
<div class="well clearfix">
|
2
|
+
<%= image_tag 'credit_cards/credit_card.gif', :id => 'credit-card-image', :class => 'pull-right', :width => '170', :height => '28' %>
|
3
|
+
<% param_prefix = "payment_source[#{payment_method.id}]" %>
|
3
4
|
|
4
|
-
<p class="field">
|
5
|
-
|
6
|
-
|
7
|
-
</p>
|
5
|
+
<p class="field">
|
6
|
+
<%= label_tag "name_on_card_#{payment_method.id}", Spree.t(:name_on_card) %><span class="required">*</span><br />
|
7
|
+
<%= text_field_tag "#{param_prefix}[name]", "#{@order.billing_firstname} #{@order.billing_lastname}", { id: "name_on_card_#{payment_method.id}", :class => 'form-control required'} %>
|
8
|
+
</p>
|
8
9
|
|
9
|
-
<p class="field" data-hook="card_number">
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
</p>
|
10
|
+
<p class="field" data-hook="card_number">
|
11
|
+
<%= label_tag "card_number", Spree.t(:card_number) %><span class="required">*</span><br />
|
12
|
+
<% options_hash = Rails.env.production? ? {:autocomplete => 'off'} : {} %>
|
13
|
+
<%= text_field_tag "#{param_prefix}[number]", '', options_hash.merge(:id => 'card_number', :class => 'form-control required cardNumber', :size => 19, :maxlength => 19, :autocomplete => "off") %>
|
14
|
+
|
15
|
+
<span id="card_type" style="display:none;">
|
16
|
+
( <span id="looks_like" ><%= Spree.t(:card_type_is) %> <span id="type"></span></span>
|
17
|
+
<span id="unrecognized"><%= Spree.t(:unrecognized_card_type) %></span>
|
18
|
+
)
|
19
|
+
</span>
|
20
|
+
</p>
|
21
|
+
<div class="row">
|
22
|
+
<div class="col-md-8 field" data-hook="card_expiration">
|
23
|
+
<%= label_tag "card_expiry", Spree.t(:expiration) %><span class="required">*</span><br />
|
24
|
+
<%= text_field_tag "#{param_prefix}[expiry]", '', :id => 'card_expiry', :class => "form-control required cardExpiry", :placeholder => "MM / YY" %>
|
25
|
+
</div>
|
26
|
+
<div class="col-md-4 field" data-hook="card_code">
|
27
|
+
<%= label_tag "card_code", Spree.t(:card_code) %><span class="required">*</span><br />
|
28
|
+
<%= text_field_tag "#{param_prefix}[verification_value]", '', options_hash.merge(:id => 'card_code', :class => 'form-control required cardCode', :size => 5) %>
|
29
|
+
<%= link_to "(#{Spree.t(:what_is_this)})", spree.content_path('cvv'), :target => '_blank', "data-hook" => "cvv_link", :id => "cvv_link" %>
|
30
|
+
</div>
|
31
|
+
</div>
|
20
32
|
|
21
|
-
|
22
|
-
<%= label_tag "card_expiry", Spree.t(:expiration) %><span class="required">*</span><br />
|
23
|
-
<%= text_field_tag "#{param_prefix}[expiry]", '', :id => 'card_expiry', :class => "required cardExpiry", :placeholder => "MM / YY" %>
|
24
|
-
</p>
|
33
|
+
<%= hidden_field_tag "#{param_prefix}[cc_type]", '', :id => "cc_type", :class => 'ccType' %>
|
25
34
|
|
26
|
-
|
27
|
-
<%= label_tag "card_code", Spree.t(:card_code) %><span class="required">*</span><br />
|
28
|
-
<%= text_field_tag "#{param_prefix}[verification_value]", '', options_hash.merge(:id => 'card_code', :class => 'required cardCode', :size => 5) %>
|
29
|
-
<%= link_to "(#{Spree.t(:what_is_this)})", spree.content_path('cvv'), :target => '_blank', "data-hook" => "cvv_link", :id => "cvv_link" %>
|
30
|
-
</p>
|
31
|
-
|
32
|
-
<%= hidden_field_tag "#{param_prefix}[cc_type]", '', :id => "cc_type", :class => 'ccType' %>
|
35
|
+
</div>
|
@@ -5,33 +5,27 @@
|
|
5
5
|
<!--[if IE 9 ]> <html class="ie ie9" lang="<%= I18n.locale %>"> <![endif]-->
|
6
6
|
<!--[if gt IE 9]><!--><html lang="<%= I18n.locale %>"><!--<![endif]-->
|
7
7
|
<head data-hook="inside_head">
|
8
|
-
<%= render :
|
8
|
+
<%= render partial: 'spree/shared/head' %>
|
9
9
|
</head>
|
10
10
|
<body class="<%= body_class %>" id="<%= @body_id || 'default' %>" data-hook="body">
|
11
|
+
<%= render partial: 'spree/shared/google_analytics.js' %>
|
12
|
+
<%= render partial: 'spree/shared/header' %>
|
11
13
|
|
12
14
|
<div class="container">
|
13
15
|
|
14
|
-
|
15
|
-
|
16
|
-
<div id="wrapper" class="row" data-hook>
|
16
|
+
<div class="row" data-hook>
|
17
17
|
|
18
18
|
<%= breadcrumbs(@taxon) %>
|
19
19
|
|
20
|
-
<%= render :
|
20
|
+
<%= render partial: 'spree/shared/sidebar' if content_for? :sidebar %>
|
21
21
|
|
22
|
-
<div id="content" class="
|
22
|
+
<div id="content" class="<%= !content_for?(:sidebar) ? "col-sm-12" : "col-sm-8 col-md-9" %>" data-hook>
|
23
23
|
<%= flash_messages %>
|
24
24
|
<%= yield %>
|
25
25
|
</div>
|
26
26
|
|
27
27
|
<%= yield :templates %>
|
28
|
-
|
29
28
|
</div>
|
30
|
-
|
31
|
-
<%= render :partial => 'spree/shared/footer' %>
|
32
|
-
|
33
29
|
</div>
|
34
|
-
|
35
|
-
<%= render :partial => 'spree/shared/google_analytics' %>
|
36
30
|
</body>
|
37
31
|
</html>
|
@@ -1,3 +1,8 @@
|
|
1
|
+
<thead>
|
2
|
+
<tr data-hook="cart_adjustments_headers">
|
3
|
+
<th class="cart-adjustment-header" colspan="6"><%= Spree.t(:order_adjustments) %></th>
|
4
|
+
</tr>
|
5
|
+
</thead>
|
1
6
|
<tbody id="cart_adjustments" data-hook>
|
2
7
|
<% if @order.line_item_adjustments.exists? %>
|
3
8
|
<% @order.line_item_adjustments.promotion.eligible.group_by(&:label).each do |label, adjustments| %>
|
@@ -1,7 +1,7 @@
|
|
1
|
-
<%= render :
|
2
|
-
<table id="cart-detail" data-hook>
|
1
|
+
<%= render partial: 'spree/shared/error_messages', locals: { target: @order } %>
|
2
|
+
<table class="table" id="cart-detail" data-hook>
|
3
3
|
<thead>
|
4
|
-
<tr data-hook="cart_items_headers">
|
4
|
+
<tr class="active" data-hook="cart_items_headers">
|
5
5
|
<th class="cart-item-description-header" colspan="2"><%= Spree.t(:item) %></th>
|
6
6
|
<th class="cart-item-price-header"><%= Spree.t(:price) %></th>
|
7
7
|
<th class="cart-item-quantity-header"><%= Spree.t(:qty) %></th>
|
@@ -10,19 +10,19 @@
|
|
10
10
|
</tr>
|
11
11
|
</thead>
|
12
12
|
<tbody id="line_items" data-hook>
|
13
|
-
<%= render partial: 'spree/orders/line_item', collection: order_form.object.line_items, locals: {order_form: order_form} %>
|
13
|
+
<%= render partial: 'spree/orders/line_item', collection: order_form.object.line_items, locals: { order_form: order_form } %>
|
14
14
|
</tbody>
|
15
15
|
<% if @order.adjustments.nonzero.exists? || @order.line_item_adjustments.nonzero.exists? || @order.shipment_adjustments.nonzero.exists? || @order.shipments.any? %>
|
16
16
|
<tr class="cart-subtotal">
|
17
|
-
<td colspan="4" align='right'><h5><%= Spree.t(:cart_subtotal, :
|
17
|
+
<td colspan="4" align='right'><h5><%= Spree.t(:cart_subtotal, count: @order.line_items.sum(:quantity)) %></h5></td>
|
18
18
|
<td colspan><h5><%= order_form.object.display_item_total %></h5></td>
|
19
19
|
<td></td>
|
20
20
|
</tr>
|
21
21
|
<%= render "spree/orders/adjustments" %>
|
22
22
|
<% end %>
|
23
|
-
<tr class="cart-total">
|
24
|
-
<td colspan="4" align='right'><h5><%= Spree.t(:total) %></h5></
|
25
|
-
<td colspan
|
23
|
+
<tr class="warning cart-total">
|
24
|
+
<td colspan="4" align='right'><h5><%= Spree.t(:total) %></h5></td>
|
25
|
+
<td class="lead" colspan><%= order_form.object.display_total %></td>
|
26
26
|
<td></td>
|
27
27
|
</tr>
|
28
28
|
</table>
|
@@ -1,6 +1,6 @@
|
|
1
1
|
<% variant = line_item.variant -%>
|
2
2
|
<%= order_form.fields_for :line_items, line_item do |item_form| -%>
|
3
|
-
<tr class="
|
3
|
+
<tr class="line-item">
|
4
4
|
<td class="cart-item-image" data-hook="cart_item_image">
|
5
5
|
<% if variant.images.length == 0 %>
|
6
6
|
<%= link_to small_image(variant.product), variant.product %>
|
@@ -20,17 +20,17 @@
|
|
20
20
|
<%= line_item_description_text(line_item.description) %>
|
21
21
|
</span>
|
22
22
|
</td>
|
23
|
-
<td class="cart-item-price" data-hook="cart_item_price">
|
23
|
+
<td class="lead text-primary cart-item-price" data-hook="cart_item_price">
|
24
24
|
<%= line_item.single_money.to_html %>
|
25
25
|
</td>
|
26
|
-
<td class="cart-item-quantity" data-hook="cart_item_quantity">
|
27
|
-
<%= item_form.number_field :quantity, :
|
26
|
+
<td class="cart-item-quantity" data-hook="cart_item_quantity" valign="center">
|
27
|
+
<%= item_form.number_field :quantity, min: 0, class: "form-control line_item_quantity", size: 5 %>
|
28
28
|
</td>
|
29
|
-
<td class="cart-item-total" data-hook="cart_item_total">
|
29
|
+
<td class="lead text-primary cart-item-total" data-hook="cart_item_total">
|
30
30
|
<%= line_item.display_amount.to_html unless line_item.quantity.nil? %>
|
31
31
|
</td>
|
32
32
|
<td class="cart-item-delete" data-hook="cart_item_delete">
|
33
|
-
<%= link_to
|
33
|
+
<%= link_to content_tag(:span, '', class: 'glyphicon glyphicon-minus-sign'), '#', class: 'delete', id: "delete_#{dom_id(line_item)}" %>
|
34
34
|
</td>
|
35
35
|
</tr>
|
36
36
|
<% end -%>
|
@@ -5,43 +5,41 @@
|
|
5
5
|
<% if @order.line_items.empty? %>
|
6
6
|
|
7
7
|
<div data-hook="empty_cart">
|
8
|
-
<
|
9
|
-
<p><%= link_to Spree.t(:continue_shopping), products_path, :
|
8
|
+
<div class="alert alert-info"><%= Spree.t(:your_cart_is_empty) %></div>
|
9
|
+
<p><%= link_to Spree.t(:continue_shopping), products_path, class: 'btn btn-default' %></p>
|
10
10
|
</div>
|
11
11
|
|
12
12
|
<% else %>
|
13
13
|
|
14
14
|
<div data-hook="outside_cart_form">
|
15
|
-
<%= form_for @order, :
|
15
|
+
<%= form_for @order, url: update_cart_path, html: { id: 'update-cart' } do |order_form| %>
|
16
16
|
<div data-hook="inside_cart_form">
|
17
17
|
|
18
|
-
<div data-hook="cart_items">
|
19
|
-
<%= render :
|
18
|
+
<div data-hook="cart_items" class="table-responsive">
|
19
|
+
<%= render partial: 'form', locals: { order_form: order_form } %>
|
20
20
|
</div>
|
21
21
|
|
22
|
-
<div class="links
|
23
|
-
|
24
|
-
<%= button_tag :
|
22
|
+
<div class="links col-md-6 navbar-form pull-right text-right" data-hook="cart_buttons">
|
23
|
+
<div class="form-group">
|
24
|
+
<%= button_tag class: 'btn btn-primary', id: 'update-button' do %>
|
25
25
|
<%= Spree.t(:update) %>
|
26
26
|
<% end %>
|
27
|
-
<%= button_tag :
|
27
|
+
<%= button_tag class: 'btn btn-lg btn-success', id: 'checkout-link', name: 'checkout' do %>
|
28
28
|
<%= Spree.t(:checkout) %>
|
29
29
|
<% end %>
|
30
30
|
</div>
|
31
|
-
|
32
31
|
</div>
|
33
32
|
<% end %>
|
34
33
|
</div>
|
35
34
|
|
36
|
-
<div id="empty-cart" data-hook>
|
37
|
-
<%= form_tag empty_cart_path, :
|
35
|
+
<div id="empty-cart" class="col-md-6 pull-left" data-hook>
|
36
|
+
<%= form_tag empty_cart_path, method: :put do %>
|
38
37
|
<p id="clear_cart_link" data-hook>
|
39
|
-
|
40
|
-
|
41
|
-
|
38
|
+
<%= submit_tag Spree.t(:empty_cart), class: 'btn btn-default' %>
|
39
|
+
<%= Spree.t(:or) %>
|
40
|
+
<%= link_to Spree.t(:continue_shopping), products_path, class: 'continue' %>
|
42
41
|
</p>
|
43
42
|
<% end %>
|
44
43
|
</div>
|
45
|
-
|
46
44
|
<% end %>
|
47
45
|
</div>
|