[Rails] Re: Simple facebook status update from rails?

2009-12-29 Thread comopasta Gr
Hi Fajrian, Thanks a lot for the pointers. I was just checking some FB connect examples. I kind of tried to avoid it since I'm not sure how much room for UI customization there is with FB connect. I'd like to avoid the boring (IMO) FB theme and buttons. The info you provided is really helpful.

Re: [Rails] Re: Question on CRON

2009-12-29 Thread David Angga
try : 55 11 01 * * regards On Wed, Dec 30, 2009 at 12:55 PM, Newb Newb wrote: > Newb Newb wrote: > > Dear All, > > i m running cron task in my application using whenever gem. > > the below code runs the rake every month. > > every 1.month, :at => '11:55pm' do > > but i want to run this rake on

[Rails] Oracle adapter problem? How to fix this?

2009-12-29 Thread pepe
Hi, My setup is: Ruby 1.8.6 Rails 2.3.5 activerecord-oracle-adapter (1.0.0.9250) I upgraded Rails and the adapter recently and I just went through hell trying to find a problem while inserting a record in a table. Rails was giving me this error: OCIError (ORA-02289: sequence does not exist):

[Rails] Re: Question on CRON

2009-12-29 Thread Newb Newb
Newb Newb wrote: > Dear All, > i m running cron task in my application using whenever gem. > the below code runs the rake every month. > every 1.month, :at => '11:55pm' do > but i want to run this rake on 1st date of every month. > how can i do it. > pls guide me on this. Some one pls help me --

[Rails] Re: Good RoR Oursourcing company

2009-12-29 Thread Robb
On Dec 29, 1:39 pm, Johan De Klerk wrote: > Why do so many big coporates choose Microsoft technology? > Management by magazine. -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-t...@goog

[Rails] Re: Question regarding entering data in a has_many relations

2009-12-29 Thread Marnen Laibow-Koser
Robert Walker wrote: > Marnen Laibow-Koser wrote: >> Ajax (specifically not an acronym according to its creator, although it >> really is one) has a very clear meaning -- asynchronous JavaScript >> server requests that don't require a page reload. The term is useful >> and I see no reason to dr

[Rails] Variable scope and RESTful methods

2009-12-29 Thread Learn By Doing
I have the usual methods in a RESTful implementation: index, new In the index method I have a variable @new_link which is not nil . At the end of the index method, I tested the value with logger.info @new_link.inspect to make sure. And the log output shows that @new_link is in fact not nill. W

[Rails] Question on CRON

2009-12-29 Thread Newb Newb
Dear All, i m running cron task in my application using whenever gem. the below code runs the rake every month. every 1.month, :at => '11:55pm' do but i want to run this rake on 1st date of every month. how can i do it. pls guide me on this. -- Posted via http://www.ruby-forum.com/. -- You recei

[Rails] Re: Question regarding entering data in a has_many relations

2009-12-29 Thread Robert Walker
Marnen Laibow-Koser wrote: > Ajax (specifically not an acronym according to its creator, although it > really is one) has a very clear meaning -- asynchronous JavaScript > server requests that don't require a page reload. The term is useful > and I see no reason to drop it -- if it's used in it

Re: [Rails] Re: Re: Good RoR Oursourcing company

2009-12-29 Thread David Angga
Try this: http://www.kiranatama.com/ :-) On Wed, Dec 30, 2009 at 6:09 AM, Johan De Klerk wrote: > Marnen, again, thanks for the input. > > On Wed, Dec 30, 2009 at 12:34 AM, Marnen Laibow-Koser < > li...@ruby-forum.com> wrote: > >> Johan De Klerk wrote: >> > "Find a developer >> > you like, and l

[Rails] Re: How to do collection_select pulldown style="width:200px"

2009-12-29 Thread Rob Bean
DAN wrote: > I figured it out finally... > > ..., { :prompt => "Select Book Type..." }, { "style" => "width:200px" } I know this is old, but I'm bumping it because it helped me out. Also, one other tip for collection_select: If you don't need the prompt, you can use this: …, {}, { "style" => "

Re: [Rails] best approach to pass hash type data in string form from Rails/Ruby to a C# app???

2009-12-29 Thread Conrad Taylor
On Tue, Dec 29, 2009 at 3:12 PM, greghauptmann wrote: > Hi, > > I need to pass (via string content of a HTTP request/response body) > name value pairs of data (like a hash) back from a Ruby on Rails > server to a C# client. > > Anyone happen to know offhand what would be the best format to do this

[Rails] Re: SQL query problem

2009-12-29 Thread Learn By Doing
Thanks everyone for your help! Happy New Year. On Dec 21, 6:24 am, Roberta wrote: > select * >  from link_table le >  where le.link_site = '3' or le.linked_site ='3' >    and not exists (select 0 >                     from link_table li >                    where li.link_site = le.linked_site >

Re: [Rails] Re: best approach to pass hash type data in string form from

2009-12-29 Thread Curtis Jennings Schofield
http://www.json.org/ list at the bottom for languages On Tue, Dec 29, 2009 at 4:17 PM, greghauptmann wrote: > do you know offhand then whether C# has a library to parse JSON or > Yaml to C# variables? > > On Dec 30, 9:15 am, Marnen Laibow-Koser wrote: >> greghauptmann wrote: >> > Hi, >> >> > I

Re: [Rails] best approach to pass hash type data in string form from Rails/Ruby to a C# app???

2009-12-29 Thread Curtis Jennings Schofield
json rocks On Tue, Dec 29, 2009 at 4:12 PM, greghauptmann wrote: > Hi, > > I need to pass (via string content of a HTTP request/response body) > name value pairs of data (like a hash) back from a Ruby on Rails > server to a C# client. > > Anyone happen to know offhand what would be the best form

Re: [Rails] AutoCompleter without the AutoComplete

2009-12-29 Thread Curtis Jennings Schofield
I did that exact thing with the way that autocomplete works - except each key is a new get. The response was a set of li elements. On Tue, Dec 29, 2009 at 5:01 PM, Ruby on Rails: Talk wrote: > Hi > > I've written a system which requires the entry of lots of customers. > > Trusting this to an OAP

Re: [Rails] Mail now in ActionMailer

2009-12-29 Thread Curtis Jennings Schofield
Great post Mikel Thanks for you hard work - i'm excited to read more. On Tue, Dec 29, 2009 at 6:15 PM, Mikel Lindsaar wrote: > OK everyone, so we finally have Mail merged into ActionMailer replacing out > TMail > This is for the 3.0 release, and not part of the 2.x tree. > I am the TMail maint

Re: [Rails] How to interpret the log file's "View:" and "DB:" numbers?

2009-12-29 Thread tommy xiao
same here,i dont konw way. But i have a try search,this code can help we. http://ramblingsonrails.com/a-rails-log-parser-to-show-how-your-actions-are-performing View usage information by running: ruby_log_parser.rb --help Example andrew:~$ ruby rails_log_parser.rb --sort median < log/development.

[Rails] Cannot gem isntall rails

2009-12-29 Thread Max Golden
newbie in ROR. Win 7 ruby 1.8.6 (2007-09-24 patchlevel 111) [i386-mswin32] run admin cmd gem install rails --include-dependencies then I got the error here: ERROR: While executing gem ... (Gem::GemNotFoundException) Could not find rails (> 0) in any repository follow the step to instal

[Rails] Mail now in ActionMailer

2009-12-29 Thread Mikel Lindsaar
OK everyone, so we finally have Mail merged into ActionMailer replacing out TMail This is for the 3.0 release, and not part of the 2.x tree. I am the TMail maintainer and I decided this year to write a ruby email handler, the Mail gem is my solution to this. Mail takes a very object oriented app

[Rails] How to interpret the log file's "View:" and "DB:" numbers?

2009-12-29 Thread Robb
I'm seeing weird numbers come up in my production log. I've looked for some kind of authoritative document describing what they mean, but haven't found it yet. Here are my best guesses: "Completed in 125ms (View: 40, DB: 6)" 6ms in "DB" ... but what exactly counts as "DB"? Is this purely the t

[Rails] AutoCompleter without the AutoComplete

2009-12-29 Thread Ruby on Rails: Talk
Hi I've written a system which requires the entry of lots of customers. Trusting this to an OAP (I know) it appears that I now have lots of duplicate customers .. which is going to cause issues. I know I can use the validate clauses in the model when it saves, but want something a little bit

[Rails] Re: best approach to pass hash type data in string form from

2009-12-29 Thread Marnen Laibow-Koser
greghauptmann wrote: > do you know offhand then whether C# has a library to parse JSON or > Yaml to C# variables? No, but the JSON and (I think) Yaml websites list a number of libraries for various languages. There's almost certainly a JSON library at the very least. > > On Dec 30, 9:15�am, M

Re: [Rails] best approach to pass hash type data in string form from Rails/Ruby to a C# app???

2009-12-29 Thread Johan De Klerk
JSON might be better suited for key=>value pairs... depends on your app i suppose. Also dont know about json support in C#, but it's pretty much a web standard as far as i know... On Wed, Dec 30, 2009 at 1:12 AM, greghauptmann wrote: > Hi, > > I need to pass (via string content of a HTTP request/

[Rails] Re: best approach to pass hash type data in string form from

2009-12-29 Thread greghauptmann
do you know offhand then whether C# has a library to parse JSON or Yaml to C# variables? On Dec 30, 9:15 am, Marnen Laibow-Koser wrote: > greghauptmann wrote: > > Hi, > > > I need to pass (via string content of a HTTP request/response body) > > name value pairs of data (like a hash) back from a R

[Rails] Re: best approach to pass hash type data in string form from

2009-12-29 Thread Marnen Laibow-Koser
greghauptmann wrote: > Hi, > > I need to pass (via string content of a HTTP request/response body) > name value pairs of data (like a hash) back from a Ruby on Rails > server to a C# client. > > Anyone happen to know offhand what would be the best format to do this > in? Probably XML I would gue

[Rails] best approach to pass hash type data in string form from Rails/Ruby to a C# app???

2009-12-29 Thread greghauptmann
Hi, I need to pass (via string content of a HTTP request/response body) name value pairs of data (like a hash) back from a Ruby on Rails server to a C# client. Anyone happen to know offhand what would be the best format to do this in? Probably XML I would guess? tks -- You received this messa

Re: [Rails] Re: Re: Good RoR Oursourcing company

2009-12-29 Thread Johan De Klerk
Marnen, again, thanks for the input. On Wed, Dec 30, 2009 at 12:34 AM, Marnen Laibow-Koser wrote: > Johan De Klerk wrote: > > "Find a developer > > you like, and let him choose (or at least have input into) the > > technology." > > > > I disagree. > > > > Never let the developer dictate the techn

Re: [Rails] Migrations, was using test data generators -- valid / invali

2009-12-29 Thread Johan De Klerk
Marnen, thanks for the feedback! Perhaps I should do more googling on the subject... and I may be ignorant here but, In terms of some of your comments: Indexing is VERY db (and db version) specific. You may have situations where a btree index is more appropriate rather than a bitmap index. With

[Rails] Windows XP - MySQL installed thru XAMPP

2009-12-29 Thread Jamie
Hi, I'm a newbie, trying to get rails up and running on my Windows environment. I have previously installed XAMPP and have been using MySQL through that installation. Now that I've installed rails, I'm trying to run rake command db:create for an application called "blog" which I created through

[Rails] Re: Re: Good RoR Oursourcing company

2009-12-29 Thread Marnen Laibow-Koser
Johan De Klerk wrote: > "Find a developer > you like, and let him choose (or at least have input into) the > technology." > > I disagree. > > Never let the developer dictate the technology. Choose whats right for > the > company in the short/medium and long term. Right -- with significant inpu

[Rails] Migrations, was using test data generators -- valid / invali

2009-12-29 Thread Marnen Laibow-Koser
Johan De Klerk wrote: > I may be completely out of line here... but > > "WTF? Don't you use migrations? That's what they're for." > > made me think that migrations aren't the be all and end all. How did what I wrote lead you to that conclusion? > There are > ALOT > of things you cant do with

[Rails] Re: help needed - undefined method `reenable' for [environment]>:Rake::Task

2009-12-29 Thread RubyonRails_newbie
it says command not found Hmmm... On 29 Dec, 22:05, Johan De Klerk wrote: > It just outputs a bit of info about your system... I dont think root access > is needed > > On Wed, Dec 30, 2009 at 12:00 AM, RubyonRails_newbie < > > > > craigwest...@googlemail.com> wrote: > > Hi Johan, > > > > Do you

[Rails] Re: Re: Re: Re: using test data generators -- valid / invali

2009-12-29 Thread Marnen Laibow-Koser
Hassan Schroeder wrote: > On Tue, Dec 29, 2009 at 9:41 AM, Marnen Laibow-Koser > wrote: > >> Sorry, Hassan. �Normally I respect your posts here very much, but in >> this case I think you're coming up with increasingly tenuous >> justifications for a very bad design decision. > > Uh, I'm not tryi

Re: [Rails] Re: help needed - undefined method `reenable' for [environment]>:Rake::Task

2009-12-29 Thread Johan De Klerk
It just outputs a bit of info about your system... I dont think root access is needed On Wed, Dec 30, 2009 at 12:00 AM, RubyonRails_newbie < craigwest...@googlemail.com> wrote: > Hi Johan, > > > Do you have ssh access? - yes i have ssh access... > > > lsb_release -a - do i run this from root? > >

[Rails] Re: help needed - undefined method `reenable' for [environment]>:Rake::Task

2009-12-29 Thread RubyonRails_newbie
Hi Johan, > Do you have ssh access? - yes i have ssh access... > lsb_release -a - do i run this from root? What does this do? Many Thanks On 29 Dec, 21:44, Johan De Klerk wrote: > Do you have ssh access? > > Run this from the command line: > > lsb_release -a > > I've had this problem before

Re: [Rails] Re: help needed - undefined method `reenable' for [environment]>:Rake::Task

2009-12-29 Thread Johan De Klerk
Do you have ssh access? Run this from the command line: lsb_release -a I've had this problem before but found it's very OS and distro specific... On Tue, Dec 29, 2009 at 11:37 PM, RubyonRails_newbie < craigwest...@googlemail.com> wrote: > Hello Johan > > > Are you on Linux? > > Yes I am I beli

[Rails] [ANN] Mongo3 - rule your mongoDB clusters!

2009-12-29 Thread DeRailed
If you mongo, please try mongo3 (www.mongo3.com) ! Mongo3 is a web app to administer you mongoDB clusters. Features: o Visualize your mongo landscape o Manage your dbs, collections and indexes o Bundled as a gem for easy install and getting started. -Fernand -- You received this message be

Re: [Rails] Re: Re: Re: using test data generators -- valid / invalid d

2009-12-29 Thread Hassan Schroeder
On Tue, Dec 29, 2009 at 9:41 AM, Marnen Laibow-Koser wrote: > Sorry, Hassan.  Normally I respect your posts here very much, but in > this case I think you're coming up with increasingly tenuous > justifications for a very bad design decision. Uh, I'm not trying to "justify" anything. :-) Perhap

Re: [Rails] Re: Good RoR Oursourcing company

2009-12-29 Thread Johan De Klerk
"Find a developer you like, and let him choose (or at least have input into) the technology." I disagree. Never let the developer dictate the technology. Choose whats right for the company in the short/medium and long term. What if the company/client gets duped into using some guy that only devel

[Rails] Re: help needed - undefined method `reenable' for [environment]>:Rake::Task

2009-12-29 Thread RubyonRails_newbie
Hello Johan > Are you on Linux? Yes I am I believe. I've uninstalled rake several times and the error is still the same. undefined method `reenable' for [environment]>:Rake::Task I've spent all day looking over thisbut now i'm a bit lost. On 29 Dec, 21:15, Johan De Klerk wrote: > Are you

Re: [Rails] Re: Re: Re: using test data generators -- valid / invalid d

2009-12-29 Thread Johan De Klerk
I may be completely out of line here... but "WTF? Don't you use migrations? That's what they're for." made me think that migrations aren't the be all and end all. There are ALOT of things you cant do with migrations when it comes to database specific deployment. eg. triggers, user defined funct

[Rails] Re: error when using facebooker

2009-12-29 Thread Marnen Laibow-Koser
fajrian wrote: > hi all, > > i am rails newbie. so, please be merciful if you found this question > stupid :D > > i want to ADD facebook capability to my project. fyi, my project is > using prototype and openlayer. the amount of work done (by others) > using prototype and openlayer is quite large

Re: [Rails] Re: help needed - undefined method `reenable' for [environment]>:Rake::Task

2009-12-29 Thread Johan De Klerk
Are you on Linux? On Tue, Dec 29, 2009 at 7:31 PM, RubyonRails_newbie < craigwest...@googlemail.com> wrote: > Update - I have also tried this, but with no luck: > http://antono.info/en/138 > (which explains to do this: sudo aptitude remove rake > sudo gem install rake > > Im at a bit of a loss no

[Rails] Re: Question regarding entering data in a has_many relations

2009-12-29 Thread Ooh_Gravy
So I've been reading just that blog entry but can't get it to work. I've create a "recipes" table with name, author and a description. I've then added a table called "steps" and updated my recipes_controller with the @recipe.steps.build line that seems to be needed. However, I get an ActionControl

[Rails] Re: missed elements in array

2009-12-29 Thread Frederick Cheung
On Dec 29, 5:33 pm, Robert Walker wrote: > Yep. A common mistake when iterating arrays. One solution is to build a > new array containing the objects you want, rather than deleting objects > that you don't want. There may be better approaches that might use less > memory though. And if you do

[Rails] Re: Question regarding entering data in a has_many relations

2009-12-29 Thread T. N.t.
Robert Walker wrote: >... > http://railscasts.com/episodes/73-complex-forms-part-1 > > This continues in episode 74 as well. With the newer accepts_nested_attributes_for method he could probably save some work/code (http://is.gd/5FLVB). -- Posted via http://www.ruby-forum.com/. -- You receiv

[Rails] Re: Showing the items visited for a non-logedin users

2009-12-29 Thread T. N.t.
Wilhelm Longshanks wrote: > Hi - I would like to implement a feature similar to "Items you have > visited" in Amazon. > The requirement is that the feature is also available for those who > are not logged-in. > > I have a User and Item models. I use Rails-default session storage. > I do not need w

[Rails] Re: Good RoR Oursourcing company

2009-12-29 Thread Marnen Laibow-Koser
Bill Barnes wrote: > We are a startup in the US and want an application built in RoR. We > area all business people and not IT people and we aren't ready to > bring software development in house. > Then why have you chosen Rails already? Sure, it's a fabulous set of technologies, but if none of

Re: [Rails] Good RoR Oursourcing company

2009-12-29 Thread James Stewart
On Mon, Dec 28, 2009 at 8:34 PM, Bill Barnes wrote: > We are a startup in the US and want an application built in RoR. We > area all business people and not IT people and we aren't ready to > bring software development in house. > > Anyone have good experiences with outsourced RoR development?

[Rails] Re: Question regarding entering data in a has_many relations

2009-12-29 Thread Marnen Laibow-Koser
Robert Walker wrote: > Marnen Laibow-Koser wrote: >> Robert Walker wrote: >> [...] >>> The view is where these things get a little more tricky. There is no >>> "one right way" to do this. It's going to depend on your specific case. >>> Often it's a good idea to allow the user to add steps by usin

[Rails] Re: Re: Re: using test data generators -- valid / invalid d

2009-12-29 Thread Marnen Laibow-Koser
Hassan Schroeder wrote: > On Tue, Dec 29, 2009 at 8:32 AM, Marnen Laibow-Koser > wrote: > >>> That didn't work but got me thinking in a workable direction, thanks. >> >> Why didn't it work? �That should be foolproof, unless I screwed up the >> syntax. > >>> User.max(:id) + 10 > NoMethodError: un

[Rails] Re: missed elements in array

2009-12-29 Thread Robert Walker
Frederick Cheung wrote: > On Dec 29, 2:21�pm, LeonS wrote: >> Hi, >> i despair in case of an array. >> I'll take some data into an array, but when i iterate the array some >> elements of the array seems to be missed, but the missing element are >> displayed in the view. >> I'm using the Plugin Rai

[Rails] Re: help needed - undefined method `reenable' for [environment]>:Rake::Task

2009-12-29 Thread RubyonRails_newbie
Update - I have also tried this, but with no luck: http://antono.info/en/138 (which explains to do this: sudo aptitude remove rake sudo gem install rake Im at a bit of a loss now.. ANy thoughts? On 29 Dec, 16:23, RubyonRails_newbie wrote: > Hello, > > I am trying to deploy my app at the moment,

[Rails] Re: Re: Re: using test data generators -- valid / invalid d

2009-12-29 Thread Robert Walker
Hassan Schroeder wrote: > I'll disagree. In this case, requiring a valid user to be associated > with > an object *is* a business decision; tomorrow, I could decide to allow > anonymous object creation, or anonymous creation in some specific > circumstances only. You just made my point quite nice

[Rails] Re: Question regarding entering data in a has_many relations

2009-12-29 Thread Robert Walker
Marnen Laibow-Koser wrote: > Robert Walker wrote: > [...] >> The view is where these things get a little more tricky. There is no >> "one right way" to do this. It's going to depend on your specific case. >> Often it's a good idea to allow the user to add steps by using AJAX to >> insert new for

[Rails] Re: Hello, help required.

2009-12-29 Thread E. Litwin
http://www.pragprog.com/titles/rails3/agile-web-development-with-rails-third-edition On Dec 29, 7:05 am, "Saj" wrote: > Hello > > I am new to Ruby on Rail. I am looking for some internet based resource, an > eBook or a tutorials on RoR. > > I shall be thankful if someone help me out. Or If you w

Re: [Rails] Re: Re: using test data generators -- valid / invalid data

2009-12-29 Thread Hassan Schroeder
On Tue, Dec 29, 2009 at 8:32 AM, Marnen Laibow-Koser wrote: >> That didn't work but got me thinking in a workable direction, thanks. > > Why didn't it work?  That should be foolproof, unless I screwed up the > syntax. >> User.max(:id) + 10 NoMethodError: undefined method `max' for # > Data inte

[Rails] Re: Re: using test data generators -- valid / invalid data

2009-12-29 Thread Robert Walker
Marnen Laibow-Koser wrote: >>> ... validates_associated is silly and circularity-prone. >>> You should be using foreign key constraints in the DB for this >> >> Well, I'll take that under advisement :-) but I would prefer to have the >> business logic in the app, and tested. > > Data integrity c

[Rails] Re: Question regarding entering data in a has_many relations

2009-12-29 Thread Marnen Laibow-Koser
Robert Walker wrote: [...] > I don't think it's silly at all. It's how I would approach this myself. > From the controller/model aspect this is pretty straight forward. For > each step you would add them like so: recipe.steps << new_step. > > The view is where these things get a little more tric

[Rails] Re: Re: using test data generators -- valid / invalid data

2009-12-29 Thread Marnen Laibow-Koser
Hassan Schroeder wrote: > On Mon, Dec 28, 2009 at 10:55 AM, Marnen Laibow-Koser > wrote: > >>> If I use a generator to create test objects and owners, I have no >>> idea what owner ids have been created, so how can I specify an >>> invalid one for test purposes? >> >> You probably don't need to.

[Rails] help needed - undefined method `reenable' for [environment]>:Rake::Task

2009-12-29 Thread RubyonRails_newbie
Hello, I am trying to deploy my app at the moment, and each time I do, I get the following error when i run a trace on it: rake db:migrate --trace (in /srv/some area/someplaceelse...) ** Invoke db:migrate (first_time) ** Invoke environment (first_time) ** Execute environment ** Execute db:migra

[Rails] Hello, help required.

2009-12-29 Thread Saj
Hello I am new to Ruby on Rail. I am looking for some internet based resource, an eBook or a tutorials on RoR. I shall be thankful if someone help me out. Or If you want to suggest any alternative path to learn fast, that will be great. I have experience in VB, ASP, some knowlege of .net and p

[Rails] Re: missed elements in array

2009-12-29 Thread Frederick Cheung
On Dec 29, 2:21 pm, LeonS wrote: > Hi, > i despair in case of an array. > I'll take some data into an array, but when i iterate the array some > elements of the array seems to be missed, but the missing element are > displayed in the view. > I'm using the Plugin Rails_Authorization. > You're de

[Rails] Re: Question regarding entering data in a has_many relations

2009-12-29 Thread Robert Walker
Ooh_Gravy wrote: > Hey there, > > I'm new to Rails and am learning by trying to write a cookbook > application. My question is about the best way to implement adding > multiple steps to a recipe. > > Imagine I have a recipe that has a title, author, description and a > number of steps/instructio

Re: [Rails] Controller belongs_to model?

2009-12-29 Thread Rick DeNatale
On Tue, Dec 29, 2009 at 9:28 AM, phil wrote: > I've never seen this before: > > class Admin::PaymentsController < Admin::BaseController >  belongs_to :order > end > > What does this mean, exactly?! > > (This code is from Spree) It's from the plugin resource_controller and makes Payments a nested

[Rails] Controller belongs_to model?

2009-12-29 Thread phil
I've never seen this before: class Admin::PaymentsController < Admin::BaseController belongs_to :order end What does this mean, exactly?! (This code is from Spree) Thanks! -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to t

[Rails] Re: Simple facebook status update from rails?

2009-12-29 Thread fajrian
have you integrated your project with facebook before you run into this problem? if so, it's not so complicated else, yes it's complicated here is the way to do so using javascript if you have integrated your application with facebook previously: use this method: http://developers.facebook.c

[Rails] Question regarding entering data in a has_many relationship.

2009-12-29 Thread Ooh_Gravy
Hey there, I'm new to Rails and am learning by trying to write a cookbook application. My question is about the best way to implement adding multiple steps to a recipe. Imagine I have a recipe that has a title, author, description and a number of steps/instructions. Instead of entering all the

Re: [Rails] Good RoR Oursourcing company

2009-12-29 Thread 高磊
You can take a try to outsource your project on www.taskcity.com. It is said that their outsourcing service is pretty good. 2009/12/29 Bill Barnes > We are a startup in the US and want an application built in RoR. We > area all business people and not IT people and we aren't ready to > bring so

[Rails] error when using facebooker

2009-12-29 Thread fajrian
hi all, i am rails newbie. so, please be merciful if you found this question stupid :D i want to ADD facebook capability to my project. fyi, my project is using prototype and openlayer. the amount of work done (by others) using prototype and openlayer is quite large, so that i can't afford to mak

[Rails] Encrypt senders pvtkey with data and with recievers pubkey

2009-12-29 Thread Vamsi Krishna
Hi All, I wanted to ensure confidentiality by encrypting some information. I also wanted to maintain non-reputability by encrypting huge data with the senders private RSA key. Here the data is first encrypted with Senders(lets say A) private key and then Recievers(lets say B) public key.To decry

[Rails] missed elements in array

2009-12-29 Thread LeonS
Hi, i despair in case of an array. I'll take some data into an array, but when i iterate the array some elements of the array seems to be missed, but the missing element are displayed in the view. I'm using the Plugin Rails_Authorization. my Code: def index if !params[:task_id] #Tasks der 1

[Rails] Re: help with WebBrick

2009-12-29 Thread Ro
I answer from myself: In my method I've opened a connection to Oracle, call a stored procedure and not closed the cursor HERE the code: conn = OCI8.new("user", "pass", "tns_name_entry") res = conn.parse("begin my_stored_procedure (:in, :out1,:out2,:out3,:out4,:out5,:out6,:out7); end;")

Re: [Rails] Re: using test data generators -- valid / invalid data

2009-12-29 Thread Hassan Schroeder
On Mon, Dec 28, 2009 at 10:55 AM, Marnen Laibow-Koser wrote: >> If I use a generator to create test objects and owners, I have no >> idea what owner ids have been created, so how can I specify an >> invalid one for test purposes? > > You probably don't need to.  But a couple of ideas come to mind

[Rails] help with WebBrick

2009-12-29 Thread Ro
Anyone knows how to fix that? [...] /set.rb:202: [BUG] Segmentation fault ruby 1.8.7 (2009-06-12 patchlevel 174) [i686-linux] Aborted [...] and server shut down :( -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group,

[Rails] Re: How to get parameters to controller from view using

2009-12-29 Thread veronika
Thanks!!! I found interesting site: http://www.codeweblog.com/ruby-on-rails-and-to-use-action-web-service-to-create-web-services/ I try to do my work the same path, but get error: "wrong number of arguments (1 for 0)". I would like to know: can I do the same without Web-client (example)? -- You r

[Rails] Re: Re: Not equal to query

2009-12-29 Thread Hemant Bhargava
Thanks conrad, 2nd worked .. :) Conrad Taylor wrote: > On Tue, Dec 29, 2009 at 2:27 AM, Hemant Bhargava > wrote: > >> I am having Bangalore in an variable. I mean lets suppose selected_city. >> Then i tried this:- >> City.find(:all, :conditions => [ "name != selected_city" ] >> >> > Try the fo

[Rails] Re: Not equal to query

2009-12-29 Thread Hemant Bhargava
Thanks Dude .. Worked .. Brijesh Shah wrote: > Hemant Bhargava wrote: >> I am having Bangalore in an variable. I mean lets suppose selected_city. >> Then i tried this:- >> City.find(:all, :conditions => [ "name != selected_city" ] >> >> Nopes this is not working .. >> >> >> > Then try with thi

Re: [Rails] Re: Not equal to query

2009-12-29 Thread Conrad Taylor
On Tue, Dec 29, 2009 at 2:27 AM, Hemant Bhargava wrote: > I am having Bangalore in an variable. I mean lets suppose selected_city. > Then i tried this:- > City.find(:all, :conditions => [ "name != selected_city" ] > > Try the following: City.find( :all, :conditions => [ "name != selected_city" ]

[Rails] Re: Not equal to query

2009-12-29 Thread Brijesh Shah
Hemant Bhargava wrote: > I am having Bangalore in an variable. I mean lets suppose selected_city. > Then i tried this:- > City.find(:all, :conditions => [ "name != selected_city" ] > > Nopes this is not working .. > > > Then try with this... City.find(:all, :conditions => [ "name != ?",selecte

[Rails] undefined method `alias_method_chain' for I18n::Backend::Simple:Class

2009-12-29 Thread rtacconi
Hi, We are running RE: ruby 1.8.7 (2009-06-12 patchlevel 174) [sparc-solaris2.10], MBARI 0x8770, Ruby Enterprise Edition 2009.10 I tried a simple web app with a controller rendering a text and is working in my PC but on the server I get: Error message: undefined method `alias_method_chain'

[Rails] Re: Not equal to query

2009-12-29 Thread Hemant Bhargava
I am having Bangalore in an variable. I mean lets suppose selected_city. Then i tried this:- City.find(:all, :conditions => [ "name != selected_city" ] Nopes this is not working .. Brijesh Shah wrote: >> But what query i have to write to find the name of all cities except >> "Bangalore" ? >>

[Rails] Re: Not equal to query

2009-12-29 Thread Brijesh Shah
Hemant Bhargava wrote: > Hi Champs, > > Hanging out with a problem.. > I can find out the name of cities with City.find(:all).. > I can find out the Bangalore city with City.find_by_name("Bangalore"). > But what query i have to write to find the name of all cities except > "Bangalore" ? > > I tri

[Rails] Not equal to query

2009-12-29 Thread Hemant Bhargava
Hi Champs, Hanging out with a problem.. I can find out the name of cities with City.find(:all).. I can find out the Bangalore city with City.find_by_name("Bangalore"). But what query i have to write to find the name of all cities except "Bangalore" ? I tried this but of no use .. City.find(:all,

[Rails] [solved] Handling initial user setup (authlogic)

2009-12-29 Thread brianp
So as of Rails 2.3.4 they've added a seeding function. see http://ryandaigle.com/articles/2009/5/13/what-s-new-in-edge-rails-database-seeding for tutorial. Basically, add a seeds.rb to the db/ folder. Fill it out with any ruby code. I used: User.create(:username => "admin", :password => "temp",

[Rails] problems with thumbnails, attachment_fu

2009-12-29 Thread brianp
Hey, I've had this problem for about 2 months and never solved it. Image model: has_attachment :content_type => :image, :max_size => 7.megabytes, :resize_to=> '1000x100>', :storage => :file_system, :thumbnails => {

[Rails] Re: has_many with different primary key

2009-12-29 Thread Akshay Gupta
Hey Frederick, Thats what i did and thought its working fine after going through the documentation. But surprisingly its not working that way its supposed to be :( Thanks Frederick Cheung wrote: > On Dec 29, 9:25�am, Akshay Gupta wrote: >> Hey Gregg Pollack, >> >> Have you found the solution

[Rails] Re: has_many with different primary key

2009-12-29 Thread Frederick Cheung
On Dec 29, 9:25 am, Akshay Gupta wrote: > Hey Gregg Pollack, > > Have you found the solution for the issue. > I'm also facing the same problem and found this is the ditto problem. > Would like to hear if you found some solution to it ?? > has_many takes a :primary_key option. Fred > Thanks >

[Rails] Re: has_many with different primary key

2009-12-29 Thread Akshay Gupta
Hey Gregg Pollack, Have you found the solution for the issue. I'm also facing the same problem and found this is the ditto problem. Would like to hear if you found some solution to it ?? Thanks Akshay -- Posted via http://www.ruby-forum.com/. -- You received this message because you are subsc

[Rails] Good RoR Oursourcing company

2009-12-29 Thread Bill Barnes
We are a startup in the US and want an application built in RoR. We area all business people and not IT people and we aren't ready to bring software development in house. Anyone have good experiences with outsourced RoR development? Any suggestions of good RoR outsource companies we should conta

[Rails] newbie question: running lighttpd

2009-12-29 Thread no_name
Hi all-- Very new, just installed rails on my Slackware Linux system. I'm trying to start a webserver on my local machine. I want to run lighttpd, but I can't seem to get it to start. I have lighttpd, mongrel, and WEBrick all installed, but I can only run WEBrick and mongrel. When I run the foll

[Rails] Showing the items visited for a non-logedin users

2009-12-29 Thread Wilhelm Longshanks
Hi - I would like to implement a feature similar to "Items you have visited" in Amazon. The requirement is that the feature is also available for those who are not logged-in. I have a User and Item models. I use Rails-default session storage. I do not need when exactly each item page is visited, b