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
require "rubygems" | |
gem "activerecord" |
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
# intermediate scaffolding example -- a roster is a list of Students in a particular course | |
> ruby script/generate scaffold Roster course:reference student:reference |
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
ArgumentError in RostersController#create | |
wrong number of arguments (1 for 0) | |
RAILS_ROOT: C:/rails20/rails_apps/gradebook | |
Application Trace | Framework Trace | Full Trace | |
app/controllers/rosters_controller.rb:44:in `params' | |
app/controllers/rosters_controller.rb:44:in `create' | |
Request |
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
<h1>New roster</h1> | |
<%= error_messages_for :roster %> | |
<% form_for(@roster) do |f| %> | |
<p> | |
<b>Course</b><br /> | |
<%= collection_select(:course, :id, @courses, :id, :name ,{:prompt => true}) %><br /> | |
</p> |
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
Ok, users should get a list of campaigns (to add or withdraw support | |
to/from whether or not they support it now. But I also want to to | |
show if they are supporting it. | |
CampaignSupporters will hold information about which users | |
currently support which campaigns. But how do i get list | |
of all campaigns so logged in user can choose which they'd | |
like to support? | |
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
is User saved after first end below? | |
class User < ActiveRecord::Base | |
has_many :campaign_supporters | |
has_many :campaigns, :through => :campaign_supporters | |
def self.create_with_omniauth(auth) | |
create! do |user| | |
user.provider = auth["provider"] | |
user.uid = auth["uid"] |
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
# TweetTest.rb | |
require 'rubygems' | |
require 'twitter' # <<<--- this is line 6 | |
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
C:\railApps\voice>rake spec | |
You have requested: | |
faraday ~> 0.7.4 | |
The bundle currently has faraday locked at 0.6.1. | |
Try running `bundle update faraday` | |
C:\railApps\voice>bundle update faraday | |
Fetching source index for http://rubygems.org/ | |
You have requested: |
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
ActiveRecord::RecordNotFound in HomeController#index | |
Couldn't find User with id=15 | |
Rails.root: C:/railApps/voice | |
Application Trace | Framework Trace | Full Trace | |
app/controllers/application_controller.rb:9:in `current_user' | |
app/views/layouts/application.html.erb:12:in `_app_views_layouts_application_html_erb__676006747_12853416' | |
Request |
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
$ git remote add origin git@github.com:SoldierCoder/Lend-Me-Your-Voice.git | |
Ed Drain@YOUR-P3FQG2KMAW /c/Lend-Me-Your-Voice (master) | |
$ git push origin master | |
Enter passphrase for key '/c/Documents and Settings/Ed Drain/.ssh/id_rsa': | |
Enter passphrase for key '/c/Documents and Settings/Ed Drain/.ssh/id_rsa': | |
Enter passphrase for key '/c/Documents and Settings/Ed Drain/.ssh/id_rsa': | |
Counting objects: 129, done. | |
Delta compression using up to 2 threads. | |
Compressing objects: 100% (112/112), done. |
OlderNewer