$30 off During Our Annual Pro Sale. View Details »
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Introduction to Spree (A Ruby on Rails E-Commer...
Search
gmacdougall
February 26, 2014
Programming
0
210
Introduction to Spree (A Ruby on Rails E-Commerce App)
Presented at ConFoo 2014.
gmacdougall
February 26, 2014
Tweet
Share
More Decks by gmacdougall
See All by gmacdougall
Practical Code Review with Gerrit
gmacdougall
0
86
Other Decks in Programming
See All in Programming
TypeScript 5.9 で使えるようになった import defer でパフォーマンス最適化を実現する
bicstone
1
1.2k
俺流レスポンシブコーディング 2025
tak_dcxi
14
8.4k
dotfiles 式年遷宮 令和最新版
masawada
1
730
手軽に積ん読を増やすには?/読みたい本と付き合うには?
o0h
PRO
1
170
【Streamlit x Snowflake】データ基盤からアプリ開発・AI活用まで、すべてをSnowflake内で実現
ayumu_yamaguchi
1
120
Rediscover the Console - SymfonyCon Amsterdam 2025
chalasr
2
160
非同期処理の迷宮を抜ける: 初学者がつまづく構造的な原因
pd1xx
1
700
手が足りない!兼業データエンジニアに必要だったアーキテクチャと立ち回り
zinkosuke
0
580
認証・認可の基本を学ぼう前編
kouyuume
0
190
これだけで丸わかり!LangChain v1.0 アップデートまとめ
os1ma
6
1.7k
Full-Cycle Reactivity in Angular: SignalStore mit Signal Forms und Resources
manfredsteyer
PRO
0
200
ZOZOにおけるAI活用の現在 ~モバイルアプリ開発でのAI活用状況と事例~
zozotech
PRO
8
5.4k
Featured
See All Featured
GitHub's CSS Performance
jonrohan
1032
470k
A designer walks into a library…
pauljervisheath
210
24k
The Cost Of JavaScript in 2023
addyosmani
55
9.3k
CSS Pre-Processors: Stylus, Less & Sass
bermonpainter
359
30k
What’s in a name? Adding method to the madness
productmarketing
PRO
24
3.8k
Exploring the Power of Turbo Streams & Action Cable | RailsConf2023
kevinliebholz
36
6.2k
The Invisible Side of Design
smashingmag
302
51k
Being A Developer After 40
akosma
91
590k
Dealing with People You Can't Stand - Big Design 2015
cassininazir
367
27k
Art, The Web, and Tiny UX
lynnandtonic
303
21k
How to Think Like a Performance Engineer
csswizardry
28
2.4k
Fight the Zombie Pattern Library - RWD Summit 2016
marcelosomers
234
17k
Transcript
Introduction to Spree A Ruby on Rails E-Commerce App by
Gregor MacDougall Twitter: @GrMacDougall Website: http://www.freerunningtech.com/
About Me Gregor MacDougall Sr. Software Developer @ FreeRunning Technologies
None
The Grand Tour rake sandbox
None
None
None
None
None
None
None
None
None
Look Familiar? • Competitors ◦ Marketplace Solutions ◦ SaaS Solutions
◦ Self-hosted Solutions ▪ Magento, VirtueMart, ZenCart, Prestashop, osCommerce, OpenCart, …
What Makes Spree Different? • Ruby on Rails • Rails
Engine • mount Spree::Core::Engine, :at => '/store' ◦ / -> Your App ◦ /store -> Spree ◦ /blog -> Something Else
How Does Spree Model Data? Product • Basic Product ◦
Name ◦ Description ◦ SKU ◦ Weight, Dimensions ◦ Price
How Does Spree Model Data? Product • Name • Description
Variant • SKU • Weight, Dimensions • Price
How Does Spree Model Data? Product - OptionType: colour Variant
- OptionValue: black Product - OptionType: colour Variant - OptionValue: red
None
How Does Spree Model Data?
None
None
None
Customizing Spree • View Customization ◦ CSS ◦ Replacing Templates
◦ Deface • Logic Customization ◦ Adding new logic ◦ Changing existing logic
xray-rails
Replacing a view Create the following file: ./app/views/spree/shared/_search.html.erb
Using Deface to Modify Templates
Deface app/views/spree/shared/_products.html.erb
Deface app/overrides/before_products.rb
Deface (Matching on Template)
Customizability Ruby Meta-Programming (pry examples)
With Great Power...
Mixed Nuts Store
Create The Nut Model rails g model Spree::Nut name:string
Create The Nut Variant Association rails g model Spree::VariantNut variant:
references nut:references
Our Models
Nut Model In Action
Modifying Spree’s Classes app/models/spree/variant_decorator.rb
Overriding Spree Functionality
Other Spree Features • Promotions & Discounts • API •
Stock Location & Inventory Tracking • ActiveMerchant Support (100+ Payment Gateways) • Full i18n support (~40 languages currently supported) • Large Library of Extensions • and much more
For More Information Spree http://www.spreecommerce.com/ http://www.github.com/spree/spree FreeRunning Technologies http://www.freerunningtech.com/
About Me Twitter: @GrMacDougall Github: https://github.com/gmacdougall E-mail:
[email protected]
Slides: http://www.freerunningtech.com/confoo
More From Me! Practical Code Review with Gerrit 9:00 AM Tomorrow (Same Room)