This file contains hidden or 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
| class AdminController < ApplicationController | |
| layout "admin" | |
| http_basic_authenticate_with :name => "user", :password => "password" | |
| end |
This file contains hidden or 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
| def index | |
| @all_coasters = Coaster.all | |
| @coasters = @all_coasters | |
| Coaster.include_root_in_json = false | |
| end |
This file contains hidden or 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
| var myFunc = function() { | |
| console.log(this); //currently outs DOMelement | |
| }; | |
| if ($('body.home').length) { | |
| $('.slideshow').cycle({ | |
| after: myFunc | |
| }); | |
| } |
This file contains hidden or 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
| namespace :flickr do | |
| desc "Pull all data from Flickr" | |
| task :pull => :environment do | |
| # Remove everything to do with the gallery | |
| #Album.destroy_all | |
| #Photo.destroy_all |
This file contains hidden or 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
| def pending_orders? | |
| orders.where(:status => Order::PENDING).exists? | |
| end |
This file contains hidden or 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
| class LoginController < ApplicationController | |
| def overview | |
| @student = Student.search params[:search] | |
| end |