Message from discussion
Facebook Authentication
Received: by 10.14.127.202 with SMTP id d50mr893887eei.25.1300023166962;
Sun, 13 Mar 2011 06:32:46 -0700 (PDT)
X-BeenThere: neo4jrb@googlegroups.com
Received: by 10.14.25.20 with SMTP id y20ls152559eey.1.p; Sun, 13 Mar 2011
06:32:45 -0700 (PDT)
Received: by 10.14.22.10 with SMTP id s10mr1052860ees.3.1300023165622;
Sun, 13 Mar 2011 06:32:45 -0700 (PDT)
Received: by 10.14.22.10 with SMTP id s10mr1052859ees.3.1300023165604;
Sun, 13 Mar 2011 06:32:45 -0700 (PDT)
Return-Path: <andreas.ro...@gmail.com>
Received: from mail-ey0-f175.google.com (mail-ey0-f175.google.com [209.85.215.175])
by gmr-mx.google.com with ESMTPS id t6si1951634eeh.0.2011.03.13.06.32.45
(version=TLSv1/SSLv3 cipher=OTHER);
Sun, 13 Mar 2011 06:32:45 -0700 (PDT)
Received-SPF: pass (google.com: domain of andreas.ro...@gmail.com designates 209.85.215.175 as permitted sender) client-ip=209.85.215.175;
Authentication-Results: gmr-mx.google.com; spf=pass (google.com: domain of andreas.ro...@gmail.com designates 209.85.215.175 as permitted sender) smtp.mail=andreas.ro...@gmail.com; dkim=pass (test mode) header...@gmail.com
Received: by eye27 with SMTP id 27so1278405eye.20
for <neo4jrb@googlegroups.com>; Sun, 13 Mar 2011 06:32:45 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
d=gmail.com; s=gamma;
h=domainkey-signature:mime-version:in-reply-to:references:date
:message-id:subject:from:to:content-type:content-transfer-encoding;
bh=0zVesU7bLH3I6rtu7cJDBDgbC+xLk1/W6GG9X3GN49w=;
b=iP7qIBs7/+hX30TqJMfnXjqTC3AZfHMShhg/wHM7p05YT1926oYlzGuQhY/aNxMliY
Pjv2yREa6Y5EFHXbdnRXPllhXV1WTmMa1qNApViwJVsW71mwN/RMMDmu+gWa3UGhk6kz
wzRdSfJD5dIx5nFnPp/dj6fOlNiyQ6gvrqw6U=
DomainKey-Signature: a=rsa-sha1; c=nofws;
d=gmail.com; s=gamma;
h=mime-version:in-reply-to:references:date:message-id:subject:from:to
:content-type:content-transfer-encoding;
b=ngpx3KlmbqqvH3CztGbNXEtSE9C0LKSbeW4FpUkOJ0K63WUUB3LJC0RQJ9rn7lX0V0
e3pTTbHDG969m3JmT8Iz2sFr3KKOo/g+uxCxRZ0b1Vh7EUkSmqylixtPmYTuQRxBAsei
pNwKYTba9vwOco7DiZIpJ4zIRx8gTu67uGdY8=
MIME-Version: 1.0
Received: by 10.14.11.31 with SMTP id 31mr4558919eew.15.1300023165372; Sun, 13
Mar 2011 06:32:45 -0700 (PDT)
Received: by 10.14.127.69 with HTTP; Sun, 13 Mar 2011 06:32:45 -0700 (PDT)
In-Reply-To: <f3f5d060-1578-484b-9bdf-6601c8af8...@f31g2000pri.googlegroups.com>
References: <340100.48791...@web29613.mail.ird.yahoo.com>
<f3f5d060-1578-484b-9bdf-6601c8af8...@f31g2000pri.googlegroups.com>
Date: Sun, 13 Mar 2011 14:32:45 +0100
Message-ID: <AANLkTi=LsGCa=2ebi+J_bFbDVSmn1Wbsx8nKW=90T...@mail.gmail.com>
Subject: Re: Facebook Authentication
From: Andreas Ronge <andreas.ro...@gmail.com>
To: neo4jrb@googlegroups.com
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
Hi
This is because save did not allow a block for initialization, but I
just added support for that on GIT HEAD
check http://neo4j.lighthouseapp.com/projects/15548-neo4j/tickets/162-creat=
e-method-should-take-a-block
On Sun, Mar 13, 2011 at 3:24 AM, whyhellothere <jose.vi...@gmail.com> wrote=
:
>
> yup, the fields are in the model ..
>
> when i comment out find_by_x_and_y and continue with creating a new
> user .. it creates a user entry in the database .. but the fields are
> blank .. still digging around to try and understand why ...
>
>
>
> class SessionsController < ApplicationController
> =A0def create
> =A0 =A0auth =3D request.env["omniauth.auth"]
> =A0# user =3D User.find_by_provider_and_uid(auth["provider"],
> auth["uid"]) || User.create_with_omniauth(auth)
> =A0 =A0user =3D User.create_with_omniauth(auth)
> =A0 =A0session[:user_id] =3D user.id
> =A0 =A0redirect_to root_url, :notice =3D> "Signed in!"
> =A0end
> end
>
>
>
> class User < Neo4j::Rails::Model
> =A0property :provider, :type =3D> String
> =A0property :uid, :type =3D> String
> =A0property :name, :type =3D> String
>
> =A0def self.create_with_omniauth(auth)
> =A0 =A0create! do |user|
> =A0 =A0 =A0user.provider =3D auth["provider"]
> =A0 =A0 =A0user.uid =3D auth["uid"]
> =A0 =A0 =A0user.name =3D auth["user_info"]["name"]
> =A0 =A0end
> =A0end
> end
>
>
>
> On Mar 12, 6:46=A0am, Oliver Bruening <obruen...@yahoo.com> wrote:
>> be sure that yout users table has a provider field and a uid field. rail=
s contructs these find methods from the columns of your tables.
>>
>> --- whyhellothere <jose.vi...@gmail.com> schrieb am Sa, 12.3.2011:
>>
>>
>>
>> > Von: whyhellothere <jose.vi...@gmail.com>
>> > Betreff: Re: Facebook Authentication
>> > An: "neo4jrb" <neo4jrb@googlegroups.com>
>> > Datum: Samstag, 12. M=E4rz, 2011 13:23 Uhr
>> > it causes the exception :
>>
>> > =A0 undefined method `find_by_provider_and_uid' for
>> > User:Class
>>
>> > On Mar 12, 4:40=A0am, whyhellothere <jose.vi...@gmail.com>
>> > wrote:
>> > >http://railscasts.com/episodes/241-simple-omniauth
>>
>> > > woops, spoke too soon ..
>> > > the callback proceeds ok, but i'm having trouble with
>> > :
>>
>> > > =A0 # sessions_controller.rb
>> > > =A0 =A0 user =3D
>> > User.find_by_provider_and_uid(auth["provider"],
>> > > auth["uid"]) || User.create_with_omniauth(auth)
>>
>> > > also, when i temporarily remove the first part and
>> > just
>> > > create_with_omniauth ..
>> > > it doesn't seem to get any information out of the auth
>> > ..
>> > > tips & suggestions greatly appreciated
>>
>> > > On Mar 10, 7:18=A0pm, whyhellothere <jose.vi...@gmail.com>
>> > wrote:
>>
>> > > > nice, that was relatively painless .. and it
>> > found the jruby-openssl
>> > > > gem this time around
>>
>> > > > THANK YOU !!
>>
>> > > > On Mar 10, 1:41=A0am, whyhellothere <jose.vi...@gmail.com>
>> > wrote:
>>
>> > > > > thanks,
>> > > > > was considering giving
>> > authlogic_facebook_connect a try,
>> > > > > but will try that first
>>
>> > > > > On Mar 10, 12:41=A0am, Oliver Bruening <obruen...@yahoo.com>
>> > wrote:
>>
>> > > > > > take a look athttp://railscasts.com/episodes/241-simple-omniau=
th
>>
>> > > > > > this is most likely the easiest way to
>> > connect to facebook with rails. the example is for twitter,
>> > but works the same way for facebook.
>>
>> > > > > > --- Andreas Ronge <andreas.ro...@gmail.com>
>> > schrieb am Do, 10.3.2011:
>>
>> > > > > > > Von: Andreas Ronge <andreas.ro...@gmail.com>
>> > > > > > > Betreff: Re: Facebook
>> > Authentication
>> > > > > > > An: neo4jrb@googlegroups.com
>> > > > > > > Datum: Donnerstag, 10. M=E4rz, 2011
>> > 08:13 Uhr
>> > > > > > > I've not tried. How far have you
>> > come
>> > > > > > > ? What's the problem ?
>>
>> > > > > > > On Thu, Mar 10, 2011 at 4:58 AM,
>> > whyhellothere <jose.vi...@gmail.com>
>> > > > > > > wrote:
>> > > > > > > > anyone out there able to get
>> > a Facebook Authentication
>> > > > > > > to work on
>> > > > > > > > Neo4j.rb ?
>>
>> > > > > > > > --
>> > > > > > > > You received this message
>> > because you are subscribed
>> > > > > > > to the Google Groups "neo4jrb"
>> > group.
>> > > > > > > > To post to this group, send
>> > email to neo4jrb@googlegroups.com.
>> > > > > > > > To unsubscribe from this
>> > group, send email to
>> > > > > > > neo4jrb+unsubscribe@googlegroups.com.
>> > > > > > > > For more options, visit this
>> > group athttp://groups.google.com/group/neo4jrb?hl=3Den.
>>
>> > > > > > > --
>> > > > > > > You received this message because
>> > you are subscribed to the
>> > > > > > > Google Groups "neo4jrb" group.
>> > > > > > > To post to this group, send email
>> > to neo4jrb@googlegroups.com.
>> > > > > > > To unsubscribe from this group,
>> > send email to neo4jrb+unsubscribe@googlegroups.com.
>> > > > > > > For more options, visit this group
>> > athttp://groups.google.com/group/neo4jrb?hl=3Den.
>>
>> > --
>> > You received this message because you are subscribed to the
>> > Google Groups "neo4jrb" group.
>> > To post to this group, send email to neo4jrb@googlegroups.com.
>> > To unsubscribe from this group, send email to neo4jrb+unsubscribe@goog=
legroups.com.
>> > For more options, visit this group athttp://groups.google.com/group/ne=
o4jrb?hl=3Den.
>
> --
> You received this message because you are subscribed to the Google Groups=
"neo4jrb" group.
> To post to this group, send email to neo4jrb@googlegroups.com.
> To unsubscribe from this group, send email to neo4jrb+unsubscribe@googleg=
roups.com.
> For more options, visit this group at http://groups.google.com/group/neo4=
jrb?hl=3Den.
>
>