Skip to content

Instantly share code, notes, and snippets.

View joaomdmoura's full-sized avatar
🏠
Working from home

João Moura joaomdmoura

🏠
Working from home
View GitHub Profile
@joaomdmoura
joaomdmoura / Codeminer TechTalk
Created August 16, 2012 17:25
List of ppl that might go to Codeminer Tech Talk
//
// Sigam o pattern abaixo
// 1 - Fulano
// 2 - Beutrano
// 3 - ....
//
1 - João Moura
Hello,
My name is João Moura, I’m a Brazilian developer, currently living in São Paulo, working on Codeminer42 as consultant and developer w/ systems engineering.
I'm also an enthusiast technologist that love open source development. I have already spoken in some events around the world like in Brazil and Italy (http://rubyday.it/talks/11/), and I really would like to have the opportunity to be one of the speakers in The British Ruby Conference and try to surprise you guys.
My proposal theme is:
Network Architecture based on Game Philosophy
Description:
With the new technologies that are being used there is a hole new range of possibilities that will start to be more on spotlight this next year, because we (developers), are starting to change our mindsets to an asynchronous and really dynamic way of architecture and development.
@joaomdmoura
joaomdmoura / facebook invite
Created May 13, 2014 20:04
facebook invite
facebookInviteFriends: function(e) {
e.preventDefault();
var leagueName = PalpiterosApp.layout.pageContent.model.attributes.name;
FB.ui({method: 'apprequests',
message: 'convidou você para o bolão '+leagueName+'',
data: {
leagueId: PalpiterosApp.layout.pageContent.model.id,
requestAuthor: PalpiterosApp.currentUser.id,
leagueToken: PalpiterosApp.layout.pageContent.model.attributes.token
}
@joaomdmoura
joaomdmoura / post_serializer.rb
Created October 20, 2014 20:22
AMS Cache Support Proposal
class PostSerializer < ActiveModel::Serializer
cache cache_key: 'my-posts', expires_in: 3.days
attributes :title, :body
has_many :comments
url :post
end
@joaomdmoura
joaomdmoura / conflict.rb
Created March 27, 2015 14:52
Conflict solved
diff --cc lib/active_model/serializer/adapter/json_api.rb
index f604b67,cd8de8e..0000000
--- a/lib/active_model/serializer/adapter/json_api.rb
+++ b/lib/active_model/serializer/adapter/json_api.rb
@@@ -16,18 -17,19 +17,33 @@@ module ActiveMode
end
def serializable_hash(options = {})
##
## SCENARIO: One Driver one Passenger (current_user) and Two pending invitations
##
{:email=>"phil.dtyyx@ride.com", :password=>"dtyyx", :id=>3608}
{:email=>"phil.xxyjk@ride.com", :password=>"xxyjk", :id=>3607}
{:email=>"phil.tsqyv@ride.com", :password=>"tsqyv", :id=>3610}
{:email=>"phil.ozsdp@ride.com", :password=>"ozsdp", :id=>3609}
##
##
## SCENARIO: One Driver one Passenger (current_user) and Two pending invitations
##
{:email=>"phil.dtyyx@ride.com", :password=>"dtyyx", :id=>3608}
{:email=>"phil.xxyjk@ride.com", :password=>"xxyjk", :id=>3607}
{:email=>"phil.tsqyv@ride.com", :password=>"tsqyv", :id=>3610}
{:email=>"phil.ozsdp@ride.com", :password=>"ozsdp", :id=>3609}
##
##
## SCENARIO: One Driver one Passenger (current_user) and Two pending invitations
##
{:email=>"phil.dtyyx@ride.com", :password=>"dtyyx", :id=>3608}
{:email=>"phil.xxyjk@ride.com", :password=>"xxyjk", :id=>3607}
{:email=>"phil.tsqyv@ride.com", :password=>"tsqyv", :id=>3610}
{:email=>"phil.ozsdp@ride.com", :password=>"ozsdp", :id=>3609}
##
##
## SCENARIO: One Driver one Passenger (current_user) and Two pending invitations
##
{:email=>"phil.dtyyx@ride.com", :password=>"dtyyx", :id=>3608}
{:email=>"phil.xxyjk@ride.com", :password=>"xxyjk", :id=>3607}
{:email=>"phil.tsqyv@ride.com", :password=>"tsqyv", :id=>3610}
{:email=>"phil.ozsdp@ride.com", :password=>"ozsdp", :id=>3609}
##
##
## SCENARIO: One Driver one Passenger (current_user) and Two pending invitations
##
{:email=>"phil.dtyyx@ride.com", :password=>"dtyyx", :id=>3608}
{:email=>"phil.xxyjk@ride.com", :password=>"xxyjk", :id=>3607}
{:email=>"phil.tsqyv@ride.com", :password=>"tsqyv", :id=>3610}
{:email=>"phil.ozsdp@ride.com", :password=>"ozsdp", :id=>3609}
##