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
| ActiveRecord::Schema.define(:version => 20110814152905) do | |
| create_table "weapons" do |t| | |
| t.string "name" | |
| t.integer "ammo" | |
| t.string "condition" | |
| end | |
| 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
| # Here is the parameters hash sent into the controller | |
| params = { zombie_id: 2, id: 1 } |
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 Weapon < ActiveRecord::Base | |
| belongs_to :zombie | |
| 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 Weapon < ActiveRecord::Base | |
| belongs_to :zombie | |
| 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 WeaponMailer < ActionMailer::Base | |
| default from: "[email protected]" | |
| def low_ammo(weapon, zombie) | |
| mail to: zombie.email, subject: "#{weapon.name} has low ammo" | |
| end | |
| 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
| <a href='#' id='displayWeaponForm'>New Weapon</a> | |
| <div id="newWeapon" style="display:none;"> | |
| <%= form_for [@zombie, Weapon.new] do |f| %> | |
| <%= f.label :name %><br /> | |
| <%= f.text_area :name %> | |
| <%= f.submit %> | |
| <% end %> | |
| </div> |
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
| create_table(:tweets) do |t| | |
| t.string :message | |
| t.string :category_name | |
| t.string :location, :limit => 30 | |
| t.boolean :show_location, :default => false | |
| t.integer :zombie_id | |
| end | |
| create_table :zombies do |z| | |
| z.string :name |
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
| <header class="seats-header"> | |
| <h1>Reserve a Seat</h1> | |
| </header> | |
| <section id="seats"> | |
| <div class="seating-chart"> | |
| <h3>- First Class -</h3> | |
| <ol class="first-class"> | |
| <li class="row"> |
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
| function setSeat(e, handler) { | |
| e.preventDefault(); | |
| $('.selected').removeClass('selected').click(handler); | |
| $(e.target).addClass('selected').unbind('click', handler); | |
| $('#seatSelected').text($(e.target).data('seat')); | |
| } | |
| function selectFirstClass(e) { | |
| setSeat(e, selectFirstClass); | |
| fetchFirstClassConfirm(); |
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
| function viewAlternateFlight(){} | |
| $('#flight-navigation a').click(viewAlternateFlight) |