Displaying 20 results from an estimated 90 matches similar to: "rails 2.3 nested forms with has_many through checkboxes"
2008 Sep 29
1
has_one :through with :source. How to alias association?
Hi to everyone,
I have the following models:
class Attachment < ActiveRecord::Base
has_attachment :content_type => [:image, ''application/pdf''],
:max_size => 3.megabytes,
:path_prefix => ''../private/attachments'',
:storage => :file_system,
:processor => :rmagick,
2008 Sep 23
2
Contional
Hi All,
I'm having trouble selecting rows to delete, that i can't seem to overcome.
Below is some sample data, i am trying to dedup the data based on each user,
and simultaneously the timestamp (at the side i have highlighted expected
row to be removed)
I've looked at the lag function but can't seem to make it work?
My logic ran along the lines of an ifelse statement and then
2005 Dec 31
0
Polymorphic many to many linking
Hi,
I''m trying to create a model where a few objects can all be linked to
each other through a central linking table. Table structure is like
this:
-- model class Computer
create table computers (
id serial,
description varchar
);
-- model Class user
create table users (
id serial,
name varchar
);
-- model class Desk
create table desks (
id serial,
location varchar
);
--
2009 Dec 15
0
Problems reloading plugin extending AR model
Hi,
I have an AR model called Entity, which is extended in a plugin like
this (this is in a file under lib/ which is required by init.rb of the
plugin):
http://github.com/dedomenon/madb_notifications/blob/master/lib/madb_notifications_lib.rb#L8
Entity.class_eval do
def user_subscribed_to_creation?(user_id)
NotificationSubscription.find(:first, :conditions => [
"source_filter
2011 Jan 19
6
rake aborted! can't convert Hash into String
Hello,
I encouter a problem when i try to do "rake db:migrate":
rake aborted!
can''t convert Hash into String
Here is the trace result:
** Invoke db:migrate (first_time)
** Invoke environment (first_time)
** Execute environment
rake aborted!
can''t convert Hash into String
/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/fileutils.rb:1408:in
2010 Feb 08
5
Why are double sided polymorphic relationships lacking in Rails?
http://stackoverflow.com/questions/2224994/why-are-double-sided-polymorphic-relationships-lacking-in-rails
--
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-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To unsubscribe from this group, send email to
2006 Aug 07
2
Getting an array of ids from form checkboxes?
Is it possible to set up a list of checkboxes so that the form
parameters are given in an array (eg {"delete_list" => [3,6,7]}) ?
At the moment I''m using
<%= check_box_tag "delete_list[#{post.id}]" %>
...which gives parameters looking like {"delete_list" => {"3" => "1",
"6" => "1",
2006 Jul 14
2
multiple options & checkboxes
Hello,
I''m trying to implement a checkbox option function, but I''m having a
problem in visualizing how it needs to be implemented.
Let me explain. I have a model (User) and another model (Category). I
want the user to be able to select multiple categories in the form of
checkboxes and have this information stored in the db.
User habtm Category
and
Category habtm User
But
2006 Jul 27
0
Can I Filter searching, via checkboxes ? I have a diagram
[img]http://img130.imageshack.us/img130/7478/filterssr8.jpg[/img]
The search box is default like a search box. The filters will all be on
by default, and clicking one of them off will remove that tables results
from the search results
Also http://www.treeview.net/treemenu/3fr_checkbox.html
Can this be done ? If so please help.. I can not figure it out yet..
--
Posted via
2006 Apr 20
0
many many checkboxes
Hi *,
Starting to try and figure out the best way to handle the next part of
my first application.
I need to provide a form which will host approx 60 checkboxes - each
respective checkbox will need to relate to a boolean (tinyint? - I
persume a boolean would be best, (ticked / not ticked)).
I have had quite a google around on this and I have seen some tutorials
where it is suggested to use
2006 Apr 22
0
Checkboxes get reset in sortable element in IE
Hi,
I am creating a list of checkboxes and text using this code:
<% count = 0 %>
<ul id="fields_list">
<% fields_ary.length.times do %>
<%= "<li id=''item" %> <%= count %> <%= "''><span class=''chkBox''> <input
type=''checkbox''></span><span
2006 Apr 23
1
checkboxes for filtered search
I have a page that renders a series of about 20 checkboxes on the
left hand side with content on the right. These checkboxes are
created from a DB and that part is all working well.
What I want to do is have a user click on a checkbox [genres] and
have the content on the right be filtered based on the checkbox
ticked. If a user clicks on more than one checkbox than only those
stories
2006 Mar 03
0
multiple checkboxes from another sql table
can i take info from an sql table and make check boxes out of it?
--
Posted via http://www.ruby-forum.com/.
2008 Jan 15
0
[ wxruby-Bugs-17108 ] Checkboxes not showing in GraphicsContext example
Bugs item #17108, was opened at 2008-01-15 11:28
You can respond by visiting:
http://rubyforge.org/tracker/?func=detail&atid=218&aid=17108&group_id=35
Category: Incorrect behavior
Group: None
Status: Open
Resolution: None
Priority: 3
Submitted By: Alex Fenton (brokentoy)
Assigned to: Alex Fenton (brokentoy)
Summary: Checkboxes not showing in GraphicsContext example
Initial Comment:
2005 Oct 26
0
observe checkboxes
Hello,
I was wondering how I could solve the following problem.
I''ve a table with a list of checkboxes like:
"<table>
<tr><td><input id=''toggleSel[]'' type=''checkbox'' value='''' /></td></tr>
<tr><td><input id=''toggleSel[]'' type=''checkbox''
2005 Oct 26
1
how to get input fields (checkboxes)
Hello,
I was wondering what the easiest way would be to get all input fields in a
form - they all have the same id like toggle[] for instance.
how could I e.g. count them? would the getElements or getInputs work for
instance and how would I use them?
thank you
_________________________________________________________________
Express yourself instantly with MSN Messenger! Download today -
2005 Aug 19
0
Form.Element.getValue for checkboxes and radios?
I notice that Form.Element.getValue() takes a single element or id and
returns the element name and value. How does one handle getting the
values of checkboxes and/or radios which share the same control name,
save getting them one at a time?
<fieldset>
<legend>Medical History</legend>
<input name="history_illness"
type="checkbox"
2006 Feb 05
1
Check/uncheck all checkboxes
Hello!
I have this page where I list all users in a table. There is checkbox in
every row. My User-model has a "checked"-attribute.
I have implemented the checkboxes like this:
<%= check_box("user[]", "checked") %>
Which outputs this:
<input id="user_12_checked" name="user[12][checked]" type="checkbox"
value="1"
2005 Dec 14
1
checkboxes
Hi,
I''ve got a form like so:
<% @companies.each do |company| %>
<%= company.name %>
<input type="checkbox" name="companies[]" value="<%= company.id %>" /><br/>
<% end %>
which posts eg. this hash:
*Parameters*: {"commit"=>"Dispatch", "companies"=>["36", "29",
2007 Feb 22
0
AJAX in-place editing of checkboxes and dropdowns?
I''m looking for a plugin or general directions on where to find code
implementing not only in-place editing of text fields, but also of
dropdowns and checkboxes. There is a recipe in "Rails Recipe", but it
only covers dropdown menus, and chances are that there is a plugin
somewhere out there.
However, I''ve only found "InPlaceControls", which, it