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
| form{ | |
| fieldset{ | |
| padding:$baseline*2 0 0 0; margin:$baseline*2 $baseline*2 $baseline*3 0; | |
| border:0; border-top:1px solid rgba( 140, 140, 140, 0.35 ); | |
| legend{ | |
| position:relative; top:-2px; padding-right:$gutter; | |
| color:$light_grey; font-weight:bold; font-size:$fsize_large; line-height:$lsize_large; | |
| } | |
| } |
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
| @import '_variables'; | |
| .node-type-resume{ | |
| h1{ | |
| margin-top:$baseline !important; | |
| .picture{ display:inline-block; margin-right:$gutter; } | |
| a.edit_my_resume, a.back_to_profile{ |
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 vc_resumes_ajax_submit(){ | |
| module_load_include( 'inc', 'vc_resumes', 'vc_resumes.fetch' ); | |
| module_load_include( 'inc', 'node', 'node.pages' ); | |
| global $user; | |
| // dpm( $_REQUEST ); | |
| $form_id = $_REQUEST['form_id']; | |
| $type = explode( '_', $form_id ); | |
| $type = $type[0]; /* This will not work with node types with a _ in their 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
| ApplicationController < ActionController::Base | |
| # Fetch the best location available to the app at the time | |
| def fetch_location | |
| if params[:location].present? # Geocode the manual location input | |
| session[:manual_location] = Geokit::Geocoders::MultiGeocoder.geocode( params[:location] ) | |
| end | |
| if session[:manual_location].present? | |
| session[:manual_location] |
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
| # The aim of this class is to take a number of ordered enumerators and then | |
| # emit their values in ascending order. | |
| # | |
| # Some assumptions: | |
| # * The enumerators passed in emit their values in ascending order. | |
| # * The enumerators emit values which are Comparable[1] with each other. | |
| # * The enumerators can be finite *or* infinite. | |
| # | |
| # This requires Ruby 1.9. The Enumerator[2] documentation might be useful. | |
| # |
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 One | |
| test: -> console.log 'test' | |
| class @Two | |
| test: -> console.log 'test' |
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
| require 'phony' | |
| Phone = Struct.new(:value) do | |
| alias_method :value, :to_s | |
| def initialize(value) | |
| @value = value.to_s | |
| 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 User | |
| active_ingredients do | |
| phone Phone, validate: true, unique: true | |
| address Address, validate: true | |
| website Url, validate: true | |
| end | |
| end | |
| require 'phony' |
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
| def create | |
| card_saver = Billing::SaveCreditCard.new(user: current_user, card: card_params) | |
| responder = respond do |r| | |
| r.success { render :success } | |
| r.failure { render :failure } | |
| end | |
| card_saver.call(responder) | |
| 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 CreditCardController < ApplicationController | |
| def create | |
| respond_with CreditCardCreator.new(params) | |
| end | |
| end | |
| class Grouper::Responder | |
| delegate :errors, to: :resource | |
| def resource |
OlderNewer