This repository has been archived by the owner on Nov 8, 2022. It is now read-only.
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
basic mobile usecases: shows, notes, memes
- Loading branch information
Showing
24 changed files
with
222 additions
and
33 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Original file line | Diff line number | Diff line change |
---|---|---|---|
@@ -0,0 +1,6 @@ | |||
%ul.rounded | |||
- collection.each do |item| | |||
%li | |||
%a.touch_load{'data-url' => polymorphic_path([item,:notes]), 'data-transition' => 'slide-left'} | |||
= item.name | |||
%span.count= item.notes.count |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Original file line | Diff line number | Diff line change |
---|---|---|---|
@@ -1,11 +1,5 @@ | |||
.toolbar | .toolbar | ||
%h1 | %h1= t('.title') | ||
Memes | %a.button.back.touch_load{'data-url' => menu_dashboard_path, 'data-transition' => 'pop-out' }= t(:done) | ||
.content | .content | ||
%h2 | = render :partial => 'memes/table' | ||
Main Menu | |||
%ul.rounded | |||
%li | |||
%a | |||
%img.icon.greenbox{ :src => "/images/mobile/tabs/flag.png" } | |||
%span.arrow |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Original file line | Diff line number | Diff line change |
---|---|---|---|
@@ -0,0 +1,5 @@ | |||
.toolbar | |||
%h1= t('stats.top_memes.short_title', :n => AppConstants.number_of_trending_memes) | |||
%a.button.back.touch_load{'data-url' => menu_dashboard_path, 'data-transition' => 'pop-out' }= t(:done) | |||
.content | |||
= render :partial => 'memes/table' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Original file line | Diff line number | Diff line change |
---|---|---|---|
@@ -0,0 +1,6 @@ | |||
%ul.rounded | |||
- collection.each do |item| | |||
%li | |||
%a.touch_load{'data-url' => polymorphic_path([item]), 'data-transition' => 'slide-left'} | |||
= item.name | |||
%span.arrow |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Original file line | Diff line number | Diff line change |
---|---|---|---|
@@ -0,0 +1,5 @@ | |||
.toolbar | |||
%h1= t('.title') | |||
%a.button.back.touch_load{'data-url' => menu_dashboard_path, 'data-transition' => 'pop-out' }= t(:done) | |||
.content | |||
= render :partial => 'notes/table' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Original file line | Diff line number | Diff line change |
---|---|---|---|
@@ -0,0 +1,23 @@ | |||
.toolbar | |||
%h1= t('.title') | |||
%a.button.back.touch_load{'data-url' => menu_dashboard_path, 'data-transition' => 'pop-out' }= t(:done) | |||
.content | |||
.name= resource.name | |||
%ul.rounded | |||
- if resource.url? | |||
%li | |||
%a.touch_load{'data-url' => resource.url, 'data-transition' => 'slide-left'} | |||
%img.icon.greenbox{ :src => "/images/mobile/tabs/aim.png" } | |||
= t(:link) | |||
%span.arrow | |||
%li | |||
%a.touch_load{'data-url' => polymorphic_path([resource.meme,:notes]), 'data-transition' => 'slide-left'} | |||
%img.icon.greenbox{ :src => "/images/mobile/tabs/aim.png" } | |||
= resource.meme.name | |||
%span.arrow | |||
%li | |||
%a.touch_load{'data-url' => polymorphic_path([resource.show]), 'data-transition' => 'slide-left'} | |||
%img.icon.greenbox{ :src => "/images/mobile/tabs/note.png" } | |||
= resource.show.short_title | |||
%span.arrow | |||
.description= resource.description |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Original file line | Diff line number | Diff line change |
---|---|---|---|
@@ -1 +1,5 @@ | |||
= render :partial => 'pages/technoexperts.html' | .toolbar | ||
%h1= t('pages.technoexperts.title') | |||
%a.button.touch_load{'data-url' => menu_dashboard_path, 'data-transition' => 'flip-right' }= t(:done) | |||
.content | |||
= render :partial => 'pages/technoexperts.html' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Original file line | Diff line number | Diff line change |
---|---|---|---|
@@ -0,0 +1,6 @@ | |||
%ul.rounded | |||
- collection.each do |item| | |||
%li | |||
%a.touch_load{'data-url' => polymorphic_path([item]), 'data-transition' => 'slide-left'} | |||
= item.short_title | |||
%span.count= item.notes.count |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Original file line | Diff line number | Diff line change |
---|---|---|---|
@@ -1,12 +1,5 @@ | |||
.toolbar | .toolbar | ||
%h1 | %h1= t('.title') | ||
Shows | %a.button.back.touch_load{'data-url' => menu_dashboard_path, 'data-transition' => 'pop-out' }= t(:done) | ||
.content | .content | ||
%h2 | = render :partial => 'shows/table' | ||
Main Menu | |||
%ul.rounded | |||
%li | |||
%a | |||
%img.icon.greenbox{ :src => "/images/mobile/tabs/flag.png" } | |||
%span.arrow | |||
.clearpanel |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Original file line | Diff line number | Diff line change |
---|---|---|---|
@@ -0,0 +1,21 @@ | |||
.toolbar | |||
%h1= resource.short_title | |||
%a.button.back.touch_load{'data-url' => menu_dashboard_path, 'data-transition' => 'pop-out' }= t(:done) | |||
.content | |||
%h2= resource.name | |||
- if resource.cover_art_url? | |||
.cover_art= image_tag(resource.cover_art_url) | |||
%ul.rounded | |||
%li | |||
%a.touch_load{'data-url' => polymorphic_path([resource,:memes]), 'data-transition' => 'slide-left'} | |||
%img.icon.greenbox{ :src => "/images/mobile/tabs/aim.png" } | |||
= t('memes.index.title') | |||
%span.arrow | |||
%li | |||
%a.touch_load{'data-url' => polymorphic_path([resource,:notes]), 'data-transition' => 'slide-left'} | |||
%img.icon.greenbox{ :src => "/images/mobile/tabs/note.png" } | |||
= t('notes.index.title') | |||
%span.arrow | |||
- if resource.credits? | |||
%h2= resource_class.human_attribute_name(:credits) | |||
%div= raw resource.credits |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Original file line | Diff line number | Diff line change |
---|---|---|---|
@@ -0,0 +1,23 @@ | |||
require 'spec_helper' | |||
|
|||
describe MemesController do | |||
render_views | |||
let!(:show) { Factory(:show) } | |||
let!(:meme) { Factory(:meme) } | |||
let!(:note) { Factory(:note, :meme => meme, :show => show) } | |||
|
|||
before do | |||
Browser.any_instance.stub(:iphone?).and_return(true) | |||
end | |||
|
|||
describe "GET index" do | |||
subject { get :index } | |||
it { should be_success } | |||
end | |||
|
|||
describe "GET top" do | |||
subject { get :top } | |||
it { should be_success } | |||
end | |||
|
|||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Original file line | Diff line number | Diff line change |
---|---|---|---|
@@ -0,0 +1,24 @@ | |||
require 'spec_helper' | |||
|
|||
describe NotesController do | |||
render_views | |||
let!(:show) { Factory(:show) } | |||
let!(:meme) { Factory(:meme) } | |||
let!(:note) { Factory(:note, :meme => meme, :show => show) } | |||
let(:resource) { note } | |||
|
|||
before do | |||
Browser.any_instance.stub(:iphone?).and_return(true) | |||
end | |||
|
|||
describe "GET index" do | |||
subject { get :index } | |||
it { should be_success } | |||
end | |||
|
|||
describe "GET show" do | |||
subject { get :show, :id => resource.id } | |||
it { should be_success } | |||
end | |||
|
|||
end |
Oops, something went wrong.