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" | |
require "bundler/setup" | |
require "mailman" | |
require 'active_support/inflections' | |
require 'action_view/helpers' | |
extend ActionView::Helpers | |
namespace :incoming_mail do |
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
after_create :update_count | |
def update_count | |
tickets = Ticket.where(:player_id => self.player_id) | |
tickets.each do |t| | |
t.count_for_player = tickets.count | |
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
<%= form_tag edit_multiple_game_flags_path(params[:game_id]) do |f| %> | |
<% @flags.each do |flag| %> | |
<%= check_box_tag "checkbox[]", flag.reportee_id %></td> | |
<% 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
<% = form_for edit_multiple_game_flags_path(params[:game_id]) ... |
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
<% form_for edit_multiple_game_flags_path(params[:game_id],@flags) do %> | |
<table class="accordion"> | |
<thead> | |
<tr> | |
<th>Select</th> | |
<th>Player</th> | |
</tr> | |
</thead> | |
<tbody> | |
<% @flags.each do |f| %> |
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
<a data-fetch="squareroot" data-param="9"><a/> |
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
<%= form_for([@game,@message_template]) do |f| %> |
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
class Managementdb | |
include HTTParty | |
def self.login(game_name) | |
case game_name | |
when "game1" | |
self.base_uri = "http://game1" | |
when "game2" | |
self.base_uri = "http://game2" | |
when "game3" |
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
Scaffold do | |
route "/" do |r| | |
controller :welcome do |c| | |
get :index do | |
html do | |
table :posts_model, :except => :secret_field | |
list :users_model | |
end | |
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
@gamer_profiles = GamerProfile.all( | |
:$or => [ | |
{"playerName" => /#{params[:search]}/}, | |
{"locale" => /#{params[:search]}/} | |
] | |
) |