Skip to content

Instantly share code, notes, and snippets.

View dwradcliffe's full-sized avatar

David Radcliffe dwradcliffe

View GitHub Profile
@dwradcliffe
dwradcliffe / myview.js.coffee
Created March 13, 2012 17:04 — forked from NickJosevski/myview.js.coffee
backbone example - serialize form + update on change
window.MyView = Backbone.View.extend({
initialize: ->
_.bindAll(this,'render')
this.template = window.JST["MyView"]
this.model.bind('change', this.render)
render: ->
$(this.el).html(this.template(this.model.toJSON()))
events: {
class Player < ActiveRecord::Base
def salary_valid_for_year? year
send("s#{year}") != 0 && send("status#{year}") != 0 && !send("status#{year}").nil?
end
def salary_for_year year
send("s#{year}")
end
{
"id": "rubygems",
"application": {
"production": {
"rails_postgresql_host" : "",
"rails_postgresql_db": "",
"rails_postgresql_user": "",
"rails_postgresql_password": "",
"s3_key": "",
"s3_secret": "",