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
window.alert(); |
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 PasswordsController < Devise::PasswordsController | |
caches_page :thanks | |
layout "floating_box" | |
skip_before_filter :require_active | |
before_filter :require_password_token, only: :edit | |
before_filter :load_reset_resource, only: :edit | |
before_filter :require_reset_resource, only: :edit | |
respond_to :html, :popup, only: [:new, :create, :thanks] |
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
In capybara tests, I get the following situations: | |
js - enabled tests | |
visit "/" - domain = localhost | |
visit "/agent" - domain = 127.0.0.1 | |
js - disabled tests | |
visit "/" - domain = localhost |
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 Herp | |
class << self | |
private | |
def foo | |
"foo" | |
end | |
public | |
def bar | |
"bar" | |
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
This POST is ignored by rails completely, It just posts and authenticity is rejected, the "_method" is rejected so rails can't rout properly, etc. | |
Rails 3.2.8 | |
Thin | |
Both local & heroku have this problem. | |
------WebKitFormBoundarymOqg5iqQUYsBo0SI | |
Content-Disposition: form-data; name="utf8" | |
✓ |
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 Location = Backbone.RelationalModel.extend({ | |
}); | |
var LocatableA = Backbone.RelationalModel.extend({ | |
relations: [{ | |
type: "HasMany", | |
key: 'locations', | |
relatedModel: Location, | |
reverseRelation: { | |
key: 'locatable' |
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
/home/zeep/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/site_ruby/1.9.1/rubygems/dependency.rb:247:in `to_specs': Could not find rails (>= 0) amongst [minitest-1.6.0, rake-0.8.7, rdoc-2.5.8] (Gem::LoadError) | |
from /home/zeep/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/site_ruby/1.9.1/rubygems/dependency.rb:256:in `to_spec' | |
from /home/zeep/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/site_ruby/1.9.1/rubygems.rb:1195:in `gem' | |
from /home/zeep/.rvm/gems/ruby-1.9.2-p290/bin/rails:18:in `<main>' | |
/home/zeep/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/site_ruby/1.9.1/rubygems/dependency.rb:247:in `to_specs': Could not find rack (>= 0) amongst [minitest-1.6.0, rake-0.8.7, rdoc-2.5.8] (Gem::LoadError) | |
from /home/zeep/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/site_ruby/1.9.1/rubygems/dependency.rb:256:in `to_spec' | |
from /home/zeep/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/site_ruby/1.9.1/rubygems.rb:1195:in `gem' | |
from /home/zeep/.rvm/gems/ruby-1.9.2-p290/bin/rackup:18:in `<main>' | |
/usr/bin/env: ruby: No such file or directory |
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
(defn map-select [row selector] | |
(apply str (concat (interpose "\t" (selector row)) "\n"))) | |
(defn tsv [rows] | |
(let [header (map-select (first rows) keys) | |
rows (apply str (for [row rows] | |
(map-select row vals)))] | |
(str header rows))) | |
; => (def p [{"a" 34 "b" 234 "c" 234} {"a" 234 "b" 234 "c" 24}]) |
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
<%- semantic_form_for(@doctor) do |form| -%> | |
<!-- if i comment this one out, the second will show --> | |
<%- form.semantic_fields_for :user_roles do |role_form| -%> | |
<%- role_form.semantic_fields_for :user do |user_form| -%> | |
<%= user_form.input(:email) %> | |
<%- end -%> | |
<%- end -%> | |
<!-- this will not render unless the prev is commented out --> | |
<%- form.semantic_fields_for :npi_record do |npi_form| -%> | |
<%= npi_form.input(:npi_number) %> |
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
<% division = f.object %> | |
<div class="division_wrap to_remove"> | |
<%= f.error_messages %> | |
<div class="division"> | |
<h4 class="division_name_edit inline"><%=h division.name %></h4> | |
<%= f.hidden_field :id %> | |
<%= f.hidden_field :name %> | |
<% if division.editable? %> | |
<a href="#" class="edit_link">Edit</a> |
NewerOlder