Hm, I found this from stackoverflow
http://stackoverflow.com/questions/7281907/rails-3-1-issue-with-javascript-include-tag-in-application-html-erb
and if I remove //= require_tree and //= turbolinks
then I can include application.js and the add/delete does work for
scaffold, but I still cannot
I actually did not rename it to default.js, but when I try to do that
and access localhost I get an error:
ExecJS::ProgramError in People#index
Showing: /app/views/layouts/application.html.erb where line #6 raised:
TypeError: Object doesn't support this property or method
and line 6 which is:
<
Mike S. wrote in post #1180984:
> In the delete link, you need to use the delete method-Rails now expects
> a delete verb, where as your code is generating a get I believe
>
> So
>
>> <%= link_to 'Delete', :controller => "people", :action
>> => "destroy", :id => e, :method => :delete %>
>
>
>
> Sen
Hello, thanks to you I have been able to add in the data. I also changed
and cleaned up the code and used the convention with regards to the
variables. I have another question regarding the destroy/deleting data,
when I click on delete, it directs me to show where i can view the data,
but does not
I dont get the error, but when I try to save the data, it seems to
reload the page again, and the data doesnt get saved. It doesn't appear
at all when i go back to /home
--
Posted via http://www.ruby-forum.com/.
--
You received this message because you are subscribed to the Google Groups "Rub
Hello all, I'm new to ruby and I am having trouble with adding new data
(name, height, weight, etc). Everytime I try to save my data, I get
this error:
No route matches [POST] "/home/new"
Rails.root: C:/Users/Jeffrey/blog
Request
Parameters:
{"utf8"=>"✓",
"authenticity_token"=>"Vgkmt3PPEobQFp
gt; the
> > alternatives?
>
> Use rake db:seed, which runs db/seeds.rb. That is what it is for.
>
> Colin
>
> >
> > Thanks,
> >
> > Bob
> >
> > --
> > You received this message because you are subscribed to the Google
>
es?
Thanks,
Bob
--
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...@googlegroups.com.
To post to this group, send emai
Hi There,
I am running an app with an AS400 for the database. in the development
environment I am getting the following error: 37000 (-104) [IBM][iSeries
Access ODBC Driver][DB2 UDB]SQL0104 - Token ` was not valid. Valid
tokens: ( TABLE LATERAL .
/usr/local/ruby/lib/ruby/gems/1.9.1/gems/activereco
am trying to refactor an app that I have inherited that was not coded
using rails best practices. I am fairly new to rails and I am doing the
tutorials and book thing, but I also need to keep making process on the
project.
I have a model th
am running ruby 1.9.2 and rails 3.2. I have active record call that is
returning nil even though the data is there. So my question is, what part
am I missing to return the records?
my model is:stores.rb
class Stores < ActiveRecord::Base
establish_connection "as400_#{RAILS_ENV}"
set_table_na
transactions. Most
examples seem to handle the transactions in the controller which I dont
like. So I have troubles getting the errors back to the controller for
better user feedback. Hence the reason I was trying to use the
TransactionAttributes module. Backfire!
Appreciate your help.
Bob
said to turn on
the Rails.backtrace_cleaner.remove_silencers!
so ive dont that.
Is there something else i can do to that would be helpful?
On Saturday, June 22, 2013 5:06:54 PM UTC-6, Bob O wrote:
>
> Im having an issue that seems to only happen when trying to use a
> transaction. Ive used trans
Im having an issue that seems to only happen when trying to use a
transaction. Ive used transactions many times in the past and Im at a loss
as to why im getting the stack level too deep problem.
SystemStackError - stack level too deep:
actionpack (3.2.13) lib/action_dispatch/middleware/reload
I've found the only way so far is to use image_tag . From rails tutorial,
<%= image_tag("image_name" , :size => "300x210" )%> the images need to be
inside the app, i've used the app/assets/images location, there's system
and public also available, but then you need to add path info.
good lu
Bob Gustafson wrote in post #1092090:
> Lance wrote in post #93083:
>> There is a method in the Postgresql adapter called reset_pk_sequence. I
>> haven't used it yet but it sounds like this is what you are looking for.
>
> I used it:
>
> Account.delete_all
> Ac
Lance wrote in post #93083:
> There is a method in the Postgresql adapter called reset_pk_sequence. I
> haven't used it yet but it sounds like this is what you are looking for.
I used it:
Account.delete_all
Account.reset_pk_sequence
but, it didn't work. The next Account.save had the :id = last
hi chaps - i've got a project where I have very limited resources on the
device rails runs on (raspberry pi) - basically i have rails server
running… then periodically i fire off rails runner Model.method (from
an external program on the device)…. all works fine but it's terribly
slow - I think it
drat another road block...
So now I wish to create Names and I can't fiond the secret sauce.
my old create action was simply a variation on the normal..something
like this..
def create
@name = Name.new(params[:name])
respond_to do |format|
if @name.save
else
end
end
end
How
Looking after the children but I think you got it - thanks :-)
two changes...
model filename from user_names.rb to user_name.rb
and as you say
class UserName < ActiveRecord::Base
gives...
ruby-1.9.2-p290 :005 > User.last.names
User Load (0.8ms) SELECT "users".* FROM "users" ORDER BY "users
Colin Law wrote in post #1054363:
> On 29 March 2012 17:17, bingo bob wrote:
>>
>> devise :database_authenticatable, :registerable,
>> NameError: uninitialized constant User::UserName
> What is that ORDER BY lower(username) doing? I don't see where that
> is co
can anyone shed any light on this...
two questions.
1) do the new relationships via the join table look wrong (hence the
console error)
2) does my data_mover script look OK?
--
Posted via http://www.ruby-forum.com/.
--
You received this message because you are subscribed to the Google Groups
Schema attached..
model summaries...
class Name < ActiveRecord::Base
attr_accessible :given, :gender, :position
has_many :user_names
has_many :users, :through => :user_names
class UserNames < ActiveRecord::Base
belongs_to :user
belongs_to :name
class User < ActiveRecord::Base
#
Thanks Colin,
I'm giving this a go but running into problems.
Is there a problem perhaps with using the join table name of UsersNames
or UserNames as it might clash with the User.username attribute.
I'll post my code later - just wondering does the name of the join table
matter at all ?
I wro
Colin Law wrote in post #1052973:
> On 23 March 2012 16:48, bingo bob wrote:
>>
>>>> Freddy (2, male)
>>>
>>> What if one of the Freddys is female? Maybe not likely with this name
>>> but there are names that can be both.
>>
>> True - i
Colin Law wrote in post #1052938:
> On 23 March 2012 09:24, bingo bob wrote:
>> "owned" by different users who may have it as a different position in
>> Freddy
>> Rod (3, male)
> A couple of questions
> Are all the Rod records identical except for which user
OK
Thanks - I've had another think about it but I'd still appreciate any
insight if possible. I had wondered if my data model is wrong but I
don't think so, it's rather simple.
Users have names and Names belong to users. It has to be like this as
Users can individually sort their names (so the
Thanks Kisha - the links are useful, I was aware of them both by despite
having a crack at this in the console (I find that's a great place to
try stuff out and experiment I can't get there).
Here's another way of looking at it, the output/result I need.
Given the schema above I need the result
No apologies for the punny title!
Anyway, here's the thing. I know what I want to do but not sure of the
right way to model it.
So far I have this in place.
User
has_many :names
User.username User.email
Name
belongs_to :user
Name.given Name.gender Name.user_id
So basically a User has a lis
> If I understand correctly, then in the case where there are several
> records with given == "fred" for example, then you want to get a Name
> object back so you can access the other attributes. But how will the
> code know which of the records with given == "fred" that you want?
> The other attr
I'm going around in circles with this one can't solve it.
I have a database with a lot of Name objects in it, some have the same
given name - ok fairly normal.
Name
given (string)
gender (string) # it's either m or f, not really relevant
position (integer) # not really relevant
user_id (i
On Feb 11, 2:33 pm, Bob Smith wrote:
> On Feb 9, 3:52 am, Peter Vandenabeele wrote:
>
>
>
> > On Thu, Feb 9,2012at 7:07 AM, Hassan Schroeder
> > > wrote:
> > > On Wed, Feb 8,2012at 8:54 PM, Bob Smith wrote:
>
> > > > What I am trying to
start of update and *POOF* all the messages are
cleared. How can I display the messages and behave like the validation
messages do ?? BTW, I'm running 2.3.9
Thanks
Bob
--
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Talk" group.
To pos
On Feb 24, 3:53 pm, Dave Aronson
wrote:
> On Fri, Feb 24, 2012 at 15:44, Bob Smith wrote:
> > I'm trying to make a delete button for child objects. When the button
> > is pressed, I want the view to stay the same to protect whatever data
> > the user has entered alread
.text_field :day_, :style => 'text-align:
right', :size => 2, :maxlength =>2, :index => nil, :autocomplete =>
"off" %>
<%= person_form.text_field :year_, :style => 'text-align:
right', :size => 4, :maxlength =>4, :index => nil, :auto
's place
end
view>
<% if !person_form.object.new_record? %>
<%= person_form.hidden_field :id, :index => nil %>
<%= link_to 'Delete', person_path(person.id), :confirm => 'Are you
sure?', :method => :delete %>
<% end %>
By the way, I'm
On Feb 9, 3:52 am, Peter Vandenabeele wrote:
> On Thu, Feb 9, 2012 at 7:07 AM, Hassan Schroeder
> > wrote:
> > On Wed, Feb 8, 2012 at 8:54 PM, Bob Smith wrote:
>
> > > What I am trying to do is have a *unique value* set in each new record
>
> > See:http
On Feb 8, 11:54 pm, Bob Smith wrote:
> On Feb 8, 7:11 am, Peter Vandenabeele wrote:
>
>
>
> > On Wed, Feb 8, 2012 at 10:39 AM, Colin Law wrote:
> > > On 8 February 2012 07:12, Bob Smith wrote:
> > > > I need a way to set a counter that will show how many
On Feb 8, 7:11 am, Peter Vandenabeele wrote:
> On Wed, Feb 8, 2012 at 10:39 AM, Colin Law wrote:
> > On 8 February 2012 07:12, Bob Smith wrote:
> > > I need a way to set a counter that will show how many of the model
> > > have been created and put this in each inst
27;ve tried new in the controller, but that's for a create action from
the app.
Thanks
Bob
--
You received this message because you are subscribed to the Google Groups "
Awesome that DNS fix in etc/hosts worked for me
Finally ..
$ sudo gem install rails
Fetching: i18n-0.6.0.gem (100%)
Fetching: multi_json-1.0.4.gem (100%)
..
Many thanks Damian!!
Bob
Damian M. wrote in post #1031895:
> MaT 2. wrote in post #1031374:
>> i really need help.. i hope so
Davis wrote:
> On Jan 18, 2012, at 3:20 PM, Bob Fleming wrote:
>
> > Hi Walter,
>
> > Thanks for the email.
>
> > I forgot to mention that despite the error the user and identity are
> > created. Just that the role field is blank in the database and you get
> > t
so I can answer your question.
If you can help with this that would be great - I'll do some googling
in the meantime.
Cheers.
On Jan 19, 8:21 am, Walter Lee Davis wrote:
> On Jan 17, 2012, at 10:26 PM, Bob Fleming wrote:
>
>
>
>
>
>
>
>
>
> > Hi,
>
>
Hi,
I'm creating a rails app using omniauth 1.0.1 on Rails 3.1.3 and ruby
1.9.2
I'm having trouble adding a select field that populates from a class
constant in my user model.
Here's my model:
class User < ActiveRecord::Base
ROLES = ["Customer","Service Supplier"]
has_many :leads
valida
On Jan 16, 12:55 pm, Walter Lee Davis wrote:
> On Jan 16, 2012, at 12:09 AM, Bob Smith wrote:
>
>
>
>
>
>
>
>
>
>
>
> > On Dec 25 2011, 12:32 am, Walter Lee Davis wrote:
> >> On Dec 25, 2011, at 12:15 AM, Bob Smith wrote:
>
> >
On Jan 16, 12:09 am, Bob Smith wrote:
> On Dec 25 2011, 12:32 am, Walter Lee Davis wrote:
>
>
>
> > On Dec 25, 2011, at 12:15 AM, Bob Smith wrote:
>
> > > On Dec 24, 1:18 pm, Walter Lee Davis wrote:
> > > Use an :after_create callback in those cases; y
ql-ruby libmysqlclient-dev
> > # for nokogiri if needed
> > sudo apt-get install libxslt-dev libxml2-dev
>
> > Colin
>
>
As long as you're new to Rails, and have no attachment to 1.9.2, I'd
recommend using 3.1, and a great book for help is
'Agile Web Devel
On Dec 25 2011, 12:32 am, Walter Lee Davis wrote:
> On Dec 25, 2011, at 12:15 AM, Bob Smith wrote:
>
>
>
>
>
> > On Dec 24, 1:18 pm, Walter Lee Davis wrote:
> > Use an :after_create callback in those cases; you will have the ID at
> > that point and you ca
How do I setup the habtm relationships I need an additional table right?
--
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 post to this group, send email to rubyonrails-talk@googlegroups.com.
T
Dave Aronson wrote in post #1040718:
> On Fri, Jan 13, 2012 at 07:21, bingo bob wrote:
>
>> User has_many names
>> Name belongs_to User
>
> So the two 'harry's in your list are two different objects? Is that a
> necessary part of your model?
>
> -Dave
Is my proposed method (while probably not the most elegant) a reasonable
way of attacking the problem?
--
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 post to this group, send email to rubyo
Hi Colin,
Sorry - just seen your question as I was writing my method above...
User has_many names
Name belongs_to User
--
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 post to this group, se
Actually, I'll try for the instance method for the male version in
name.rb..
def find_similar_male
# get all users
users = User.all
# get all male names
names = Name.male
# get the similar names
similar_names = []
# loop users...
users.each do |user|
# loop names
user.nam
Actually - thinking it through this is an instance method I believe,
acts on an instance of a name. Kind of talking out loud here.
--
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 post to thi
.
Basically for any given name, I'd like a method that returns other names
from *other users lists* where they have that given name in the list
(phew what a mouthful, not sure if that's explained correctly, I think
so).
For example, I'd like to do this.
given user Bob has a list of
ee you
used .first to set the id. Will this help me see who was selected by
the radio buttons ??
Bob
--
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-talk@googlegroups.com.
To unsu
On Dec 20, 3:53 am, Colin Law wrote:
> On 20 December 2011 07:03, Bob Smith wrote:
>
> > I'm doing a list of family members, each with aradiobutton for head
> > of household. After the household record and the records for each
> > person are created, it is easy to se
, and this isn't updated after the record
is created. Any way to fix this? By the way, I'm using rails 2.3.9
until I have these problems worked out to get a clean app to upgrade..
Thanks
Bob
--
You received this message because you are subscribed to the Google Groups "Ruby
on Ra
Hi all,
I want host my first rails application with rails playground (
http://railsplayground.com/ ).
please, can some one who have hosted with them post a step by step
guide for me?
Tanx in advance
--
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Ta
d a way to do this with different variables referenced in the
radio_button call.
Please help with this or show me a different way to go..
By the way, I'm using Rails 2.3.9
Thanks
Bob
--
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Talk&quo
id number that doesn't exist yet. How can I
get the id of the record after it is saved and put it in
household.hoh ? Here is part of the app. By the way, I'm still using
2.3.9 until these problems are gone.
Thanks
Bob
_people.html.erb
<%= link_to_function "Add
were useless. This just got the
values needed with $f and out them in local cells that I could access.
Bob
On Jul 23, 8:12 pm, Walter Lee Davis wrote:
> On Jul 23, 2011, at 2:33 AM, Bob Smith wrote:
>
>
>
> > The problem with putting this in the controller is that there isn'
Just an update to this. I was trying to do the same thing, specifically
have a Rails3 app read some state from the session set by Rails2. I got
it working by doing what Brad M. suggested, making Rails3 aware of the
Rails2 class that was missing.
I included the definition of ActionController::Fl
3 seems angry about the
fields_for that defines person_form in Rails 2.
I'm trying to do this in Rails 3 and having no luck.. Please help
Thanks
Bob Smith
--
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Talk" group.
To post to
see anything about elm.up and elm.down
except a prototype page that showed how to move around an ordered
list.
By the way, thanks for all the help.
Bob
On Jul 22, 7:05 am, Walter Lee Davis wrote:
> On Jul 22, 2011, at 3:25 AM, Bob Smith wrote:
>
>
>
> > The purpose of this b
g the radio_button call with a
and with no luck.
<%= radio_button "household", "hoh", person.id %>
To me, it looks like I'm either not setting the class name correctly,
or not looking for them right. Please help.
Bob
On Jul 20, 9:44 am, Walter Lee Davis wrote:
&
base. That will avoid a lot of problems in
the future.
Bob
--
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-talk@googlegroups.com.
To unsubscribe from this group, send ema
ial with a different id, household_person_1001,
household_person_1030, etc. I can't see a way to get all the person
records into a JavaScript array. Please help.
Bob
--
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Talk" group.
To
It is an issue with your version of you rake gem. Check out the
answer here:
http://stackoverflow.com/questions/6085610/rails-rake-problems-uninitialized-constant-rakedsl
On Jul 14, 2:51 pm, Manu Bangia wrote:
> Hi,
>
> I am on section 7.4.2 of the tutorial. However when I try to migrate my
> h
---
Bob Clewell wants to stay in better touch using some of Google's coolest new
products.
If you already have Gmail or Google Talk, visit:
http://mail.google.com/mail/b-f21ede377a-70949d830e-freBZA5fpIuiLDqn2XbQNwawR6k
Y
---
Bob Clewell wants to stay in better touch using some of Google's coolest new
products.
If you already have Gmail or Google Talk, visit:
http://mail.google.com/mail/b-f21ede377a-d7fd4f0723-H9AgzRQhCrP1oYIQZOxCHYEka74
Y
I am trying to use the tabs function from jQuery UI in a Rails app. I
am using a helper for the navigation and I would like to keep it that
way. The code in my helper is:
def links_for_navigation
html = ""
html = <
Courses
Parts
Categories
<% link_to "Co
The reason for the redirect_to is to end the process after the file is
created at the index page
so the user doesn't have to find his way back. Is there a way to go to
the start or index page maybe?
Bob
On Jun 7, 12:03 am, radhames brito wrote:
> On Mon, Jun 6, 2011 at 3:41 PM, Bob Smit
:layout =>
'pdf_report'),
:filename => "ID List
for " + @today.strftime('%m-%d-%y') + ".pdf" }
end
Then the error is caused by a redirect_to(households_url)
Bob
On Jun 6, 3:19 pm, radhames brit
re
was a method that acted almost like redirect_to, but wouldn't cause
the error. Please help...
Thanks
Bob
--
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Talk" group.
T
I found it, but Firefox doesn't seem to like having this changed.
Bob
On Apr 22, 5:01 pm, Colin Law wrote:
> On 22 April 2011 21:53, Bob Smith wrote:
>
> > They are tiny on my display and a bigger one would be easier for my
> > users to find/use.
>
> > This is f
database, changed headings in web pages, maybe
more reports. I would like to keep one source tree to make updates
easier, but I don't know a way to do this. Please help.
Thanks
Bob Smith
--
You received this message becaus
I would like to pay to start a new open source project where sounds
can be manipulated with Socks sound processing and saved to a file
system with Paperclip. Are you interested in working on that project?
--
You received this message because you are subscribed to the Google Groups "Ruby
on Rail
Hi all
I want to connect my app to MSSQL but when i type
rake db:migrate
an erro occured like this:
←[31mCould not find gem 'odbc (>= 0, runtime)' in any of the gem sources
listed in your Gemfile.←[0m
this is my YML file:
development:
adapter: sqlserver
mode: odbc
dsn: ontrack
host: B
Thanks Colin, I'll give that a spin.
The example code in the gem does seem odd.
--
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 post to this group, send email to rubyonrails-talk@googlegroup
Any ideas?
--
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 post to this group, send email to rubyonrails-talk@googlegroups.com.
To unsubscribe from this group, send email to
rubyonrails-talk
I'm using this gem https://github.com/justintv/APNS to send push
notifications to an iPhone app and amazingly it works for single
notifications, such that I can do...
APNS.send_notification(Device.first.device_token,'test message')
Works great...
Now it should be a simple task (as per the docs t
Hi,
After hosting my sample app for file upload on heroku using the FREE
account, it does not work properly. However, everything works fine on
my local machine. Please help
FOR FILE UPLOAD::
// controller.rb
def uploadFile
if params[:upload] == nil
redirect_to(:action => :home, :noti
They are tiny on my display and a bigger one would be easier for my
users to find/use.
This is for rails 2 & 3. I am using 2 now, but upgrading to 3 as we
speak..
Thanks
Bob
--
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Talk" gro
rails app under rails 3.0.5.
the command that started all this was:
rvm install 1.9.2 -C --with-openssl-dir=$HOME/.rvm.usr --with-iconv-
dir=$HOME/.rvm.usr
Thanks for any help
Bob
--
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Talk" gro
anyone done anything like this before?
--
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 post to this group, send email to rubyonrails-talk@googlegroups.com.
To unsubscribe from this group, sen
I have a method on my model that looks like this.
def self.itunes_update
# don't run it if it's already running
if Setting.first.update_lock?
puts "updates locked"
# it's not running right now so run it
else
all_apps = self.all
all_apps.each do |app|
# do stuff with each
Hi,
has anyone any idea on how to distribute a BLACKBERRY APPLICATION
( i.e .jad and .cod files)
using rails? I would want a little example on how to achieve this on
heroku.
Regards
Ken
--
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Talk" group.
T
Thanks for yours, I hear your ideas.
I'm not hearing anything massive that I haven't done or need to change.
I think I'll stay where I am for now and see how I go - updated_at
column is indexed.
Thanks for the tips re the JSON, I had done a tweak on that in the model
already by overriding the
The following method in my rails app is called very, very frequently on
incoming requests and results in model objects being rendered as JSON.
All is working fine, but this thing has to be as efficient and fast as
possible. So far I've added an index to updated_at and I've enabled
mod_deflate on th
Is this to do with the T and Z delimiters not being recognised by mysql?
--
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 post to this group, send email to rubyonrails-talk@googlegroups.com.
T
Or to put it another way, what's the best/correct way to specify
DATETIMEs in a URL.
--
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 post to this group, send email to rubyonrails-talk@google
Logging now on in production for a while. so that helps.
When the URL is crafted this way it works...(I thought I'd cracked it)
IP/apps.json?date_from=2011-01-28%2013:58:38&date_to=2011-01-28%2013:58:38
log
Parameters: {"date_to"=>"2011-01-28 13:58:38",
"date_from"=>"2011-01-28 13:58:38"}
I thought that's how you had to format dates in a URL to have them
recognised by rails.
I'll try it the same as on the console then.
--
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 post to
Ok, that makes sense, but how do I see the SQL generated in production.
It's logged by default in dev, but not in prod AFAIK.
--
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 post to this gro
Thanks for verifying that Philip.
Guess I'll try and dive into the code and figure out how to fix it
this weekend.
If anybody has any tips or ideas, let me know.
On Jan 28, 12:03 pm, Philip Hallstrom wrote:
> On Jan 27, 2011, at 8:28 PM, bob wrote:
>
> > It seems to me lik
OK, tested...
on my server, in production,
./script/console
>> App.time_query("2011-01-28 13:58:38","2011-01-28 13:58:38")
=> [#>
so it works... returns a single app as I might expect
in the browser I do...
http://server_ip/apps.json?date_from=2011-01-28T13:58:38Z&date_to=2011-01-28T13:58:38
Peter Hickman wrote in post #978144:
> Do you have the same database on the two machines (ie both running
> MySQL or something).
Yes - same DB on both machines, mysql.
> As this is a method in a model have you checked it from the console in
> production mode on the production server? If it doesn'
Same thing - it works on my MacBook in prod mode with the production
data loaded. Not on my server though.
--
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 post to this group, send email to r
I'll elaborate with code and URLs if it helps but I'll start just
describing the problem and seeing if anyone can help me out with some
ideas.
I have a method which returns some objects as json via a time_query
method on my model - the time query takes a couple of parameters
date_from and date_to.
1 - 100 of 600 matches
Mail list logo