[Rails] Re: how to add current time as default value

2013-07-01 Thread JoeEd E.
Okay, so it turns out that does not work either. Here is the actual syntax: execute "ALTER TABLE tablename CHANGE column_name column_name TIMESTAMP DEFAULT CURRENT_TIMESTAMP" You have to put the column name in twice as well as specify the datatype again. Also, you may be wondering why I am

[Rails] Re: how to add current time as default value

2013-07-01 Thread JoeEd E.
If Loganathan's answer does not work, try this: I had to use execute "ALTER TABLE system_settings ALTER created_time SET DEFAULT CURRENT_TIMESTAMP" (instead of NOW()) -- Posted via http://www.ruby-forum.com/. -- You received this message because you are subscribed to the Google Groups "Ruby

Re: [Rails] cancan roles issue

2013-07-01 Thread Walter Lee Davis
On Jul 1, 2013, at 6:22 PM, Phil wrote: > Rails 3.2.11 > Ruby 2 > > > Hi, > > I am building my first rails app and decided to use Devise(2.2.4) and > Cancan(1.6.10) for auth and role management. The auth part works nicely but I > haven't been able to get cancan working correctly. I have one

[Rails] cancan roles issue

2013-07-01 Thread Phil
Rails 3.2.11 Ruby 2 Hi, I am building my first rails app and decided to use Devise(2.2.4) and Cancan(1.6.10) for auth and role management. The auth part works nicely but I haven't been able to get cancan working correctly. I have one role setup(admin). But when I try view the users index page

[Rails] Creating a nested attributes form for polymorphic/single table inheritance associations

2013-07-01 Thread Andrew Havens
I am working on a form (using SimpleForm) that allows you to edit embedded associations. The problem that I'm running into is that the nested models are subclasses so they are different types with potentially different fields. I'm creating hidden forms for each type of model, and using JavaScri

Re: [Rails] Re: Re: [HELP] Couldn't find Search with id= from controller

2013-07-01 Thread Colin Law
On 28 June 2013 21:29, cornelius wilson wrote: > Colin Law wrote in post #1113657: >> On 26 June 2013 16:01, cornelius wilson wrote: Colin >>> >>> How would I be able to reverse it so that it searches for the term as >>> oppose to the numeric id of the search options. As I would like for it

[Rails] Re: Color sequence on Rails console in Windows

2013-07-01 Thread kei koba
Thanks, I tried pry as you suggest to. But it seems that pry sometimes take mistakes for coloring and remain ANSI sequence chars. I attached a image for example. - Upper part of it is irb on ConEmu. - Lower part of it is pry on com.exe. Attachments: http://www.ruby-forum.com/attachment/8557/5bb55

[Rails] [ANN] Invoker - 0.1.1 release, A gem for managing processes in development environment

2013-07-01 Thread Hemant Kumar
Hello Folks, Invoker is a gem for managing processes in development environment. You can install the gem via: ~> gem install invoker And you can clone the code from: http://github.com/code-mancers/invoker After Installing gem, you need to create a configuration file: [rails] direc

[Rails] pro bono rails help for my non-profit

2013-07-01 Thread Neeraj Kapoor
Hello! My name is Neeraj Kapoor and I'm writing on behalf of the Learn To Be Foundation, a 501(c)3 non-profit organization dedicated to providing free, one-on-one, online tutoring to K-8 students in underserved schools and communities. Through the use of a real-time virtual whiteboard with vo

[Rails] Re: “Add 'gem sqlite3'' to your Gemfile”

2013-07-01 Thread Joel Pearson
No problem, we're here to help :) -- Posted via http://www.ruby-forum.com/. -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscr...

[Rails] Re: Multiple nested attributes of the same type

2013-07-01 Thread Rick
the answer is to be found here: http://guides.rubyonrails.org/association_basics.html On Sunday, June 30, 2013 2:56:59 PM UTC-4, Ruby-Forum.com User wrote: > > Hi all, > > 0 down vote favorite > > > I have two models - "symbols" and "users". Among other attributes, > symbols has "created_by_i

[Rails] Re: “Add 'gem sqlite3'' to your Gemfile”

2013-07-01 Thread Matt Hall
It works! It works! Thank you, Mr. Pearson. I was able to download your sqlite files and follow your instructions and it worked. I had trouble using the guide you linked. The directions were clear, but my environment didn't like the filed it extracted because it couldn't find the libversion_num

[Rails] Re: Color sequence on Rails console in Windows

2013-07-01 Thread Joel Pearson
Aha, found it. I added Pry to the gemfile, replaced IRB with Pry in the config, and created a .pryrc file with a command to turn the colours on. -- Posted via http://www.ruby-forum.com/. -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.

[Rails] Re: Color sequence on Rails console in Windows

2013-07-01 Thread kei koba
Thanks, conemu is very good. It just helps me! -- Posted via http://www.ruby-forum.com/. -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-tal

[Rails] Re: Color sequence on Rails console in Windows

2013-07-01 Thread Joel Pearson
I've installed conemu, it looks useful. How do you get Rails to output colour characters to the console? -- Posted via http://www.ruby-forum.com/. -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To unsubscribe from this group and stop r

[Rails] Re: PDF generation with gif and tiff images

2013-07-01 Thread Andrew R.
to generate pdf files , you can try more generator softwares, i can share with you the pdf generator i am using currently and you can have a try. http://www.rasteredge.com/how-to/csharp-imaging/pdf-creating/ -- Posted via http://www.ruby-forum.com/. -- You received this message because you ar