Hello men
U can use method pluck
@interviews.pluck(:created_at)
select return array relations
2013/11/27 Cluter Vipic li...@ruby-forum.com
Hi Folks,
I have a model called Interview. I want retrieve from the model database
a list (maybe is much better say array) with some fields.
man
2013/11/27 Rogerio Medeiros arge...@gmail.com
Hello men
U can use method pluck
@interviews.pluck(:created_at)
select return array relations
2013/11/27 Cluter Vipic li...@ruby-forum.com
Hi Folks,
I have a model called Interview. I want retrieve from the model database
a list
Pq voce nao faz isso no lado cliente?
2013/5/27 Alcelyo Roberto alce...@gmail.com
Blz pessoal ,
Estou com um problema para traduzir o método distance_of_time_in_words,
só retorna em ingles ( 3 Days , 4 hours E 35 Minutes ), o resto da app está
toda traduzida com I18N, as datas, as
try
[:subject_id, :book_id, :chapter_id, :section_id, :subsection_id,
:minisection_id].each do |k|
@#{k.to_s} = session[k] if session[k].present?
end
2013/2/17 Dave Castellano li...@ruby-forum.com
Hi,
As I continue learning to program, I am finding things I think can
probably be done in a
[:subsection_id] if
session[:subsection_id].present?
@minisection_id = session[:minisection_id] if
session[:minisection_id].present?
2013/2/17 Rogerio Medeiros arge...@gmail.com
try
[:subject_id, :book_id, :chapter_id, :section_id, :subsection_id,
:minisection_id].each do |k|
@#{k.to_s} = session[k
See u database schema
2012/8/13 Lucas Lima de Souza lucaslim...@gmail.com
Hello!
I'm trying to render a template this way (below), but the object is nil at
_category.html.erb file.
index.html.erb
%= render @categories %
_category.html.erb
%=category.name %
error:
undefined
Guru Cifani lol
2012/5/23 thiagocifani cifani.thi...@gmail.com
Are u using mocha? If you are using mocha, I think you should write
something like that:
mock('post', hash)
regards
2012/5/23 Kleber Shimabuku klebershimab...@gmail.com
Hi guys,
I'm starting to write tests and I writing
simple way to do that. I really want to avoid that, but
the best solution that I can see is to duplicate the code of the first two
scopes on find_visibles.
Thanks,
Gustavo
On Mon, May 21, 2012 at 10:25 PM, Rogerio Medeiros arge...@gmail.comwrote:
try
escopo: find_visibles, lambda
try
escopo: find_visibles, lambda { find_in_coverage.find_know_missing}
2012/5/21 Gustavo de Sá Carvalho Honorato gustavohonor...@gmail.com
The problem of the first solution is that find_in_coverage |
find_known_missing combined that way does not return a scope. It returns
two arrays each
Phone.where(area_code in (?) and number in (?), [440,441,443],
[23233233,23231212,12121212])
2012/4/24 Rafael C. de Almeida almeida...@gmail.com
On Apr 24, 5:34 am, vishal singh vishal.singh...@gmail.com wrote:
Hi,
Phone.find(:all, :conditions=[area_code in ? and number in
using concatenation in your query?
Walter
On Apr 24, 2012, at 1:11 PM, Rafael C. de Almeida almeida...@gmail.com
wrote:
On Apr 24, 2:55 pm, Rogerio Medeiros arge...@gmail.com wrote:
Phone.where(area_code in (?) and number in (?), [440,441,443],
[23233233,23231212,12121212])
That would
Hello
in ur app, get models
Dir['app/models/*.rb'].map {|f| File.basename(f,
'.*').camelize.constantize }
def get_model_names_sub
Module.constants.select do |constant_name|
constant = eval constant_name
if not constant.nil? and constant.is_a? Class and
http://sachachua.com/blog/p/22184/
2012/4/4 CC Chen li...@ruby-forum.com
Hi all,
I install Ruby1.9.2po0 and Rails3.2.3 on RedHat5
When I create a project rails nwe chapter
It show below error message:
*
Installing sqlite3
13 matches
Mail list logo