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
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
Binary file
|
Binary file
|
@@ -67,11 +67,11 @@ Spree.ready ($) ->
|
|
67
67
|
url: url,
|
68
68
|
success: (data) ->
|
69
69
|
coupon_code_field.val('')
|
70
|
-
coupon_status.addClass("success").html("Coupon code applied successfully.")
|
70
|
+
coupon_status.addClass("alert-success").html("Coupon code applied successfully.")
|
71
71
|
return true
|
72
72
|
error: (xhr) ->
|
73
73
|
handler = JSON.parse(xhr.responseText)
|
74
|
-
coupon_status.addClass("error").html(handler["error"])
|
74
|
+
coupon_status.addClass("alert-error").html(handler["error"])
|
75
75
|
$('.continue').attr('disabled', false)
|
76
76
|
return false
|
77
77
|
})
|
@@ -1,6 +1,6 @@
|
|
1
1
|
/*
|
2
|
-
* This is a manifest file that includes stylesheets for spree_frontend
|
3
|
-
*= require
|
4
|
-
*=
|
5
|
-
*=
|
2
|
+
* This is a manifest file that includes stylesheets for spree_frontend
|
3
|
+
*= require spree/frontend/frontend_bootstrap
|
4
|
+
*= require_self
|
5
|
+
*= require_tree .
|
6
6
|
*/
|
@@ -1,61 +1,4 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
|
4
|
-
$
|
5
|
-
$c_red: #e45353 !default; /* Error red */
|
6
|
-
|
7
|
-
$layout_background_color: #FFFFFF !default;
|
8
|
-
$title_text_color: #404042 !default;
|
9
|
-
$body_text_color: #404042 !default;
|
10
|
-
$link_text_color: #00ADEE !default;
|
11
|
-
|
12
|
-
$product_background_color: #FFFFFF !default;
|
13
|
-
$product_title_text_color: #404042 !default;
|
14
|
-
$product_body_text_color: #404042 !default;
|
15
|
-
$product_link_text_color: #BBBBBB !default;
|
16
|
-
|
17
|
-
/*--------------------------------------*/
|
18
|
-
/* Fonts import from remote
|
19
|
-
/*--------------------------------------*/
|
20
|
-
@import url(//fonts.googleapis.com/css?family=Ubuntu:400,700,400italic,700italic|&subset=latin,cyrillic,greek,greek-ext,latin-ext,cyrillic-ext);
|
21
|
-
|
22
|
-
/*--------------------------------------*/
|
23
|
-
/* Font families
|
24
|
-
/*--------------------------------------*/
|
25
|
-
$ff_base: 'Ubuntu', sans-serif !default;
|
26
|
-
|
27
|
-
/*--------------------------------------
|
28
|
-
| Font sizes
|
29
|
-
|--------------------------------------
|
30
|
-
|- Navigation
|
31
|
-
| */
|
32
|
-
$header_navigation_font_size: 14px !default;
|
33
|
-
$horizontal_navigation_font_size: 16px !default;
|
34
|
-
$main_navigation_header_font_size: 14px !default;
|
35
|
-
$main_navigation_font_size: 12px !default;
|
36
|
-
/*|------------------------------------
|
37
|
-
|- Product Listing
|
38
|
-
| */
|
39
|
-
$product_list_name_font_size: 12px !default;
|
40
|
-
$product_list_price_font_size: 16px !default;
|
41
|
-
$product_list_header_font_size: 20px !default;
|
42
|
-
$product_list_search_font_size: 14px !default;
|
43
|
-
/*|------------------------------------
|
44
|
-
|- Product Details
|
45
|
-
| */
|
46
|
-
$product_detail_name_font_size: 24px !default;
|
47
|
-
$product_detail_description_font_size: 12px !default;
|
48
|
-
$product_detail_price_font_size: 20px !default;
|
49
|
-
$product_detail_title_font_size: 14px !default;
|
50
|
-
/*|------------------------------------
|
51
|
-
|- Basic
|
52
|
-
| */
|
53
|
-
$heading_font_size: 24px !default;
|
54
|
-
$sub_heading_font_size: 14px !default;
|
55
|
-
$button_font_size: 12px !default;
|
56
|
-
$input_box_font_size: 13px !default;
|
57
|
-
$base_font_size: 12px !default;
|
58
|
-
$border_color: lighten($body_text_color, 60) !default;
|
59
|
-
$default_border: 1px solid $border_color !default;
|
60
|
-
$button_border_color: rgba(0, 138, 189, .75) !default;
|
61
|
-
$table_head_color: lighten($body_text_color, 60) !default;
|
1
|
+
/*--------------------------------
|
2
|
+
Colors
|
3
|
+
--------------------------------*/
|
4
|
+
$brand-primary: #1c5c92;
|
@@ -0,0 +1,102 @@
|
|
1
|
+
//Add your custom bootstrap variables here, see https://github.com/twbs/bootstrap-sass/blob/master/vendor/assets/stylesheets/bootstrap/_variables.scss for full list of variables.
|
2
|
+
|
3
|
+
@import "bootstrap-sprockets";
|
4
|
+
@import "variables";
|
5
|
+
@import "bootstrap";
|
6
|
+
|
7
|
+
// -- Spree Custom Header and Footer ---------------------
|
8
|
+
#spree-header {
|
9
|
+
background: $brand-primary asset-url('spree_header.jpg') center center;
|
10
|
+
background-size: cover;
|
11
|
+
margin-bottom: $line-height-computed;
|
12
|
+
|
13
|
+
#header {
|
14
|
+
background: rgba($gray-darker, 0.4);
|
15
|
+
padding: $line-height-computed 0;
|
16
|
+
}
|
17
|
+
|
18
|
+
#logo {
|
19
|
+
margin-bottom: 10px;
|
20
|
+
|
21
|
+
img {
|
22
|
+
width: 306px;
|
23
|
+
}
|
24
|
+
}
|
25
|
+
|
26
|
+
.nav a {
|
27
|
+
color: white;
|
28
|
+
|
29
|
+
&:hover, &:focus {
|
30
|
+
background: rgba($gray-darker, 0.4);
|
31
|
+
}
|
32
|
+
}
|
33
|
+
|
34
|
+
.navbar {
|
35
|
+
border: 0;
|
36
|
+
margin-bottom: 0;
|
37
|
+
}
|
38
|
+
}
|
39
|
+
|
40
|
+
#spree-footer {
|
41
|
+
background: $gray-dark;
|
42
|
+
padding-top: $padding-base-horizontal;
|
43
|
+
margin-top: $line-height-computed;
|
44
|
+
color: white;
|
45
|
+
}
|
46
|
+
|
47
|
+
// -- Spree Layout Custom Rules -------------------------
|
48
|
+
|
49
|
+
.alert-notice { @extend .alert-success; }
|
50
|
+
.alert-error, .alert-registration_error { @extend .alert-danger; }
|
51
|
+
.alert-alert { @extend .alert-info; }
|
52
|
+
|
53
|
+
.product-body {
|
54
|
+
height: 170px;
|
55
|
+
}
|
56
|
+
|
57
|
+
.progress-steps {
|
58
|
+
margin-top: $line-height-computed;
|
59
|
+
}
|
60
|
+
|
61
|
+
h1 {
|
62
|
+
margin-bottom: 30px;
|
63
|
+
}
|
64
|
+
|
65
|
+
// Center cart line items
|
66
|
+
table {
|
67
|
+
&.table > tbody > tr {
|
68
|
+
&.line-item td, &.stock-item td {
|
69
|
+
vertical-align: middle;
|
70
|
+
}
|
71
|
+
}
|
72
|
+
|
73
|
+
&#line-items {
|
74
|
+
> tbody, > tfoot {
|
75
|
+
> tr > td {
|
76
|
+
vertical-align: middle;
|
77
|
+
|
78
|
+
&.order-qty {
|
79
|
+
text-align: center;
|
80
|
+
}
|
81
|
+
}
|
82
|
+
}
|
83
|
+
}
|
84
|
+
}
|
85
|
+
|
86
|
+
// Footer links
|
87
|
+
#footer-left a {
|
88
|
+
color: lighten($brand-primary, 20);
|
89
|
+
|
90
|
+
&:hover {
|
91
|
+
color: lighten($brand-primary, 10);
|
92
|
+
}
|
93
|
+
}
|
94
|
+
|
95
|
+
// Updated credit-card image
|
96
|
+
#credit-card-image {
|
97
|
+
margin-top: -10px;
|
98
|
+
}
|
99
|
+
|
100
|
+
.existing-credit-card-list td {
|
101
|
+
padding: 5px;
|
102
|
+
}
|
@@ -4,11 +4,9 @@ module Spree
|
|
4
4
|
# checkout which has nothing to do with updating an order that this approach
|
5
5
|
# is waranted.
|
6
6
|
class CheckoutController < Spree::StoreController
|
7
|
-
ssl_required
|
8
|
-
|
9
7
|
before_action :load_order_with_lock
|
10
|
-
|
11
|
-
|
8
|
+
before_filter :ensure_valid_state_lock_version, only: [:update]
|
9
|
+
before_filter :set_state_if_present
|
12
10
|
|
13
11
|
before_action :ensure_order_not_completed
|
14
12
|
before_action :ensure_checkout_allowed
|
@@ -48,22 +46,35 @@ module Spree
|
|
48
46
|
end
|
49
47
|
|
50
48
|
private
|
51
|
-
def ensure_valid_state
|
52
|
-
unless skip_state_validation?
|
53
|
-
if (params[:state] && !@order.has_checkout_step?(params[:state])) ||
|
54
|
-
(!params[:state] && !@order.has_checkout_step?(@order.state))
|
55
|
-
@order.state = 'cart'
|
56
|
-
redirect_to checkout_state_path(@order.checkout_steps.first)
|
57
|
-
end
|
58
|
-
end
|
59
49
|
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
50
|
+
def unknown_state?
|
51
|
+
(params[:state] && !@order.has_checkout_step?(params[:state])) ||
|
52
|
+
(!params[:state] && !@order.has_checkout_step?(@order.state))
|
53
|
+
end
|
54
|
+
|
55
|
+
def insufficient_payment?
|
56
|
+
params[:state] == "confirm" &&
|
57
|
+
@order.payment_required? &&
|
58
|
+
@order.payments.valid.sum(:amount) != @order.total
|
59
|
+
end
|
60
|
+
|
61
|
+
def correct_state
|
62
|
+
if unknown_state?
|
63
|
+
@order.checkout_steps.first
|
64
|
+
elsif insufficient_payment?
|
65
|
+
'payment'
|
66
|
+
else
|
67
|
+
@order.state
|
66
68
|
end
|
69
|
+
end
|
70
|
+
|
71
|
+
def ensure_valid_state
|
72
|
+
if @order.state != correct_state && !skip_state_validation?
|
73
|
+
flash.keep
|
74
|
+
@order.state = correct_state
|
75
|
+
redirect_to checkout_state_path(@order.state)
|
76
|
+
end
|
77
|
+
end
|
67
78
|
|
68
79
|
# Should be overriden if you have areas of your checkout that don't match
|
69
80
|
# up to a step within checkout_steps, such as a registration step
|
@@ -113,8 +124,8 @@ module Spree
|
|
113
124
|
end
|
114
125
|
|
115
126
|
# Provides a route to redirect after order completion
|
116
|
-
def completion_route
|
117
|
-
spree.order_path(@order)
|
127
|
+
def completion_route(custom_params = nil)
|
128
|
+
spree.order_path(@order, custom_params)
|
118
129
|
end
|
119
130
|
|
120
131
|
def setup_for_current_state
|
@@ -143,13 +154,6 @@ module Spree
|
|
143
154
|
@differentiator.missing.each do |variant, quantity|
|
144
155
|
@order.contents.remove(variant, quantity)
|
145
156
|
end
|
146
|
-
|
147
|
-
# @order.contents.remove did transitively call reload in the past.
|
148
|
-
# Hiding the fact that the machine advanced already to "payment" state.
|
149
|
-
#
|
150
|
-
# As an intermediary step to optimize reloads out of high volume code path
|
151
|
-
# the reload was lifted here and will be removed by later passes.
|
152
|
-
@order.reload
|
153
157
|
end
|
154
158
|
|
155
159
|
if try_spree_current_user && try_spree_current_user.respond_to?(:payment_sources)
|