On 18 December 2012 05:10, Praveen BK wrote:
> Adding @ to a variable doesn make the variable instance variable, its
> convention that are followed while writing a ruby program, I think...
>
> Here I have a variable x = 10, in my controller how can i access it in
> view without using cookies.
Don
Adding @ to a variable doesn make the variable instance variable, its
convention that are followed while writing a ruby program, I think...
Here I have a variable x = 10, in my controller how can i access it in
view without using cookies.
--
Posted via http://www.ruby-forum.com/.
--
You receiv
Adding @ to a variable doesn make the variable instance variable, its
convention that are followed while writing a ruby program, I think...
Here I have a variable x = 10, in my controller how can i access it in
view without using cookies.
--
Posted via http://www.ruby-forum.com/.
--
You rece
Hi,
I have a model,
class UserComment
belongs_to :user
validates :player_id, :presence => true
validates :comment, :uniqueness => { :scope => :player_id}
partial "comments" from User.
= simple_form_for @user, :html => {:class => 'comment-form'}, :remote =>
true do |f|
%fieldset
= f.fields
Hello,
I have the problem posted at this address :
https://github.com/svenfuchs/globalize3/issues/172.
I created a new project with a new model and I integrated globalize3. I
created a migration like this :
class CreatePages < ActiveRecord::Migration
def up
create_table :p
On Mon, Dec 17, 2012 at 10:15 PM, Avi wrote:
> Hello All,
>
> I have two tables:
> user has_many room
> room belongs_to user
>
> When a new user is created, I want to save the room through some default
> values at the same time.
> How to do this by using callbacks?
>
> after_save or after_create
On Dec 17, 2012, at 1:41 PM, Erwin wrote:
> I am a Rails dev (Rails 3.2.9 / MySQL / Haml ) working on some pilot projects
> testing using TDD to get them running fine according to customer
> requirements. You can compare this work to some 'story-boards' describing the
> main features of the si
I am a Rails dev (Rails 3.2.9 / MySQL / Haml ) working on some pilot
projects testing using TDD to get them running fine according to customer
requirements. You can compare this work to some 'story-boards' describing
the main features of the site
Once done, I'll transfer the code to my good PH
Hello All,
I have two tables:
user has_many room
room belongs_to user
When a new user is created, I want to save the room through some default
values at the same time.
How to do this by using callbacks?
after_save or after_create ?
& I want to use blocks with callbacks.
Any suggestions??
Tha
On Monday, December 17, 2012 9:07:07 AM UTC, Maddy wrote:
>
> Hi everyone Good Afternoon,
>
> I done adding expire header by put the following code into my product
> model.
>
> :s3_headers => { 'Cache-Control' => 'max-age=315576000', 'Expires'
> =>
> 10.years.from_now.httpdate },
>
> But
> Instead of Student.where(:course_id => @exam.course_id) use
> @exam.course.students
Good. Thanks Colin :)
--
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
On 17 December 2012 08:59, Praveen BK wrote:
> Hi, I want pass a variable(which is not a instance variable) from
> controller to view in rails application, onclick I am going to
> controller and fetching data with ajax. Since the page is not reloaded I
> cant set the variable in cookies. So is the
On 17 December 2012 08:49, Lorenz Blackbird wrote:
> Sorry for the double post.
>
> I try to use squeel gem in this way:
>
> <%= f.select :students_ids, Student.where(:course_id =>
> @exam.course_id).map { |student| [student.name, student.id] }, { }, {
> multiple: true } %>
Instead of Student.whe
On 17 December 2012 06:56, Jordon Bedwell wrote:
> On Mon, Dec 17, 2012 at 12:49 AM, Samir
> wrote:
>> <% @likes.each do |like| %>
>> <%= like['name'] %>
>> <% end %>
>>
>> Can some one tell me how to use puts here. so that i can get my outputs in a
>> new line format.
>
> <%= %> is puts to the
On Sunday, December 16, 2012 7:45:57 PM UTC-8, rubyrookie wrote:
>
> I want to take some elements from json string from
> facebook
> {"algorithm":"HMAC-SHA256","expires":1355720400,"issued_at":1355715753,"oauth_token":"AChvQA2sBAClBE0B40nw7YqrAuYNhOZCYJ4sZAMSZC8VFZAz81s2mndYbS7t2DxTzFkQ88FmX
On Sunday, 16 December 2012 19:49:11 UTC+5:30, Nikolay wrote:
>
> After entering data in http://localhost:3000/checkout/update/address form
> i getting the following error:
>
> NoMethodError in Spree::CheckoutController#update
>
> undefined method `user_id=' for #
>
>
> A error chunk of Developm
Hi everyone Good Afternoon,
I done adding expire header by put the following code into my product
model.
:s3_headers => { 'Cache-Control' => 'max-age=315576000', 'Expires'
=>
10.years.from_now.httpdate },
But its work only while i add new product and image.
Already i have 100 of pro
Hi, I want pass a variable(which is not a instance variable) from
controller to view in rails application, onclick I am going to
controller and fetching data with ajax. Since the page is not reloaded I
cant set the variable in cookies. So is there any way to pass a
variable(which is not an instance
Sorry for the double post.
I try to use squeel gem in this way:
<%= f.select :students_ids, Student.where(:course_id =>
@exam.course_id).map { |student| [student.name, student.id] }, { }, {
multiple: true } %>
I replaced .all with .where(condition). After two days of tests I find
this solutio
> I think you need to add a relationship between a course and a user and
> use that relationship to figure out that list of student choices eligible
> for the exam.
In this project, any student can join only one course. In fact, the
relationship between students and course is:
belongs_to :course
20 matches
Mail list logo