Skip to content

Instantly share code, notes, and snippets.

View davidpelaez's full-sized avatar

David Pelaez davidpelaez

  • Vlipco
  • Bogota, Colombia
View GitHub Profile
class EntriesController < ApplicationController
respond_to :json
def index
respond_with Entry.all
end
def show
respond_with Entry.find(params[:id])
end
@davidpelaez
davidpelaez / application.rb
Created August 10, 2012 19:10
Application.rb booter that skips DB on rake environment
require File.expand_path('../boot', __FILE__)
def skipping_active_record?
if ENV['SKIP_DB'] then true else false end
end
if skipping_active_record? then
puts "Loading app without ActiveRecord since SKIP_DB is set"
# Pick the frameworks you want:
@davidpelaez
davidpelaez / gist:3420545
Created August 21, 2012 23:45
Modified version of customForms to affect markup when checkbox state changes
/*
* jQuery Custom Forms Plugin 1.0
* www.ZURB.com
* Copyright 2010, ZURB
* Free to use under the MIT license.
* http://www.opensource.org/licenses/mit-license.php
*/
(function( $ ){
%h5.cutter
%i.cuttericon-info
Titulo
= javascript_include_tag "applicant/applicant"
= stylesheet_link_tag "applicant"
%header.container.ten.columns.centered
.row
.four.columns#logo
- @organization.logo? ? logo = @organization.logo.url : logo = "cvive_logo.png"
= image_tag logo
.four.columns#job_name
%h2 Sollicitatie voor #{@job.title}
{"job":{"title":"Temporary Job","intro_text":"Some text for intro","end_date":"2012-09-11","response_time":"5","locale":"EN","email_notifications":true,"status":"draft","outro_text":"Thank you.","intro_video_attributes":{"external_id":"41070886","service":"vimeo"},"outro_video_attributes":{"external_id":"41070886","service":"vimeo"},"questions_attributes":[{"title":"Qtitle","text":"Qtext","position":1,"video_attributes":{"external_id":"41070886","service":"vimeo"},"video_external_id":null,"video_service":null,"questionsCount":1}]}}
Hi Reyndert,
https://github.com/cvive/cvive/issues/49
check that issue to see that's all you requested is solved as much a we could. The localeapp allows you to collaborate and add the missing translations. We closed some other minor issues not listed, but we manages to complete because we are really getting desperate and are giving our best to end this project by two months ago :P
The issue with the test question has been incredibly hard, we've been working for hours on it and it's out of our hands. We're waiting for feedback from Vimeo, but their support hours are exactly as ours, so we need to wait until the morning.
In the meantime, make sure to use localeapp to tune and complement translations as you prefer.
@davidpelaez
davidpelaez / gist:3735903
Created September 17, 2012 06:50
en safari
Unsafe JavaScript attempt to access frame with URL http://trigion.bitremix.com/apply/3 from frame with URL http://player.vimeo.com/video/41069774?api=1&autoplay=1&player_id=vimeo_video_41069774. Domains, protocols and ports must match.
http://trigion.bitremix.com/favicon.icoFailed to load resource: the server responded with a status of 404 (Not Found)
Unable to post message to http://player.vimeo.com. Recipient has origin http://trigion.bitremix.com.
2Unsafe JavaScript attempt to access frame with URL http://trigion.bitremix.com/apply/3 from frame with URL http://player.vimeo.com/video/41070154?api=1&autoplay=1&player_id=vimeo_video_41070154. Domains, protocols and ports must match.
Unable to post message to http://player.vimeo.com. Recipient has origin http://trigion.bitremix.com.
2Unsafe JavaScript attempt to access frame with URL http://trigion.bitremix.com/apply/3 from frame with URL http://player.vimeo.com/video/41071413?api=1&autoplay=1&player_id=vimeo_video_41071413. Domains, protocols and ports must m
playerIsReady:(id)=>
#console.log "#{id} vimeo player is ready"
#The methods in these events must be addressed by their complete name, as the backbone
#notation doesn't work with froogaloop.
@player.addEvent('finish', VimeoVideoView.prototype.finish)
@player.addEvent 'finish', ->
console.log "Video finished"
@davidpelaez
davidpelaez / vimeo_video_view.js
Created September 17, 2012 19:13
Backbone view in Coffescript to interact with vimeo iframe player
class CviveApplicant.Views.VimeoVideoView extends Backbone.View
template: Handlebars.templates["applicant_templates/vimeo_player"]
initialize:->
console.log "init VimeoVideoView"
render:->
console.log "render VimeoVideoView"