Displaying 20 results from an estimated 2000 matches similar to: "mutiple select"
2008 Apr 10
3
option_groups_from_collection_for_select with a ActiveRecord::Base single object
Rails documentation gives examples of using
option_groups_from_collection_for_select with two tables/objects.
How could it be done with one?
Example that almost works:
I have a form to enter address from both the United States and Canada.
It has the following:
====new.html.erb====
<%= select_tag(
:state,
option_groups_from_collection_for_select(
State.countries,
:country,
2006 Jul 13
1
error_messages_for
I can''t seem to figure out how to validate a few fields some1 please
help me out
model---------
class Record < ActiveRecord::Base
validates_presence_of :sw, :flex
end
controller------------
class RecordController < A;;icationController
def new
@record = Rrecord.new
@product = Product.find(params[''product_id''])
end
def create
2007 Aug 12
10
about chinese display
hello:
I have built a project with Instant Rails.Now only a database and a
scaffold based on a product model have finished.But when i inputted
"../admin/list" in my browser,i found my chinese characters cound not
display normally.Then i made five steps:
1 ajusting encoding in my browser menu
2 in "C:\InstantRails\conf_files\my.ini"directory,making sure
2010 Mar 16
3
collection_select has_many
hi
i have two models:
GeoRegion & GeoRegionSub
which have a has_many relation to each other.
how can include the has_many relation in the collection_select helper? i
want to have that dropdown where the parent is in black and the children
indented.
<%= collection_select :dl,:parent_id, GeoRegion.all.????, :id, :title %>
thx
--
You received this message because you are subscribed
2011 Sep 10
0
Mutiple vertical reference lines with a dotplot
Dear R helpers
I would like to plot vertical reference lines for yearly averages the
variable being plotted. In this case there are three years 2002, 2009 and
2010 for a variable Resc_Gt.
I've attempted to get the 2002 mean plotting (2.27) using the 'abline'
command but no joy.
Ideally I would like to be able to compute and plot the means of the three
years automatically using a
2002 Dec 06
2
Mutiple page trellis plots with relation = "free" or "sliced"
Hello,
Has anyone out there encountered a problem like this:
xyplot(Plasma ~ Serum | Analyte,
data = sp.df,
aspect = 1,
layout = c(1, 1, 200),
scales = list(relation = "free")
)
Gives the error:
Error in pretty(x[is.finite(x)], ...) : x must be numeric
On the other hand, this works (but I don't want the default of having
everything on the same
2006 Jul 15
4
updating multiple records with form
I have an app that has two models -- products and details. I''m building
a form that allows a user to create a new product and specify a
description, etc.
The form needs to allow for creation of multiple items in the details
model/table. for example, I have a block of form items that collect
info for the men''s version of the product -- inventory count for each
size, etc. And
2010 Dec 20
8
Mutiple virtualmachines Live migration at the same time with Xen
Dear all
The following process is about trying to do the " live migration at the same time with 5 Virtual machines ", but there is somthing problem with it.
Process:
yogi-pc2: # xm migrate --live vm01 pc2 & xm migrate --live vm02 pc2 & xm migrate --live vm03 pc2 & xm migrate --live vm04 pc2 & xm migrate --live vm05 pc2[1] 29983
[2] 29984
[3] 29985
[4]
2013 Oct 20
4
- multiple virtual host on httpd
hi everybody,
how I do to set a mutiple virtual host on httpd configuration?
I need to host multiple sites with the same IP address
what must be the httpd.conf configuration file and into /etc/httpd/conf.d/?
thanks in advance
kind regards,
./p
2007 Dec 08
3
Uploading photos using facebook & attachment_fu
Hi All,
I''m trying to use a form to upload a photo that I will save using
attachment_fu. I''m very new to Facebookr so I apologize if this is covered
somewhere, but I''m kind of stumped.
Here''s what I''m doing now:
<% facebook_form_for(:my_object, :url => { :action => ''upload_photo'', :id =>
params[:id] }, :html => {
2007 Jul 12
2
USB Modem with asterisk
I can use a USB modem with asterisk to connect to the
PSTN network right? It'll serve the same functionality
as an FXO card? Also, any idea if I can get these
modems with mutiple ports (12 or 24)?
Thanks,
Doug
____________________________________________________________________________________
Get your own web address.
Have a HUGE year through Yahoo! Small Business.
2006 Feb 16
21
RoR VS Rails ???
I didn''t get a chance to go to this meeting debating WebObjects Vs
Rails, but here''s a report about it:
http://desperatepundit.com/blog/cremes/technology/2006/02/15/WebObjects-versus-Ruby-On-Rails.html
I don''t get what he''s saying, hand coding the model? yeah, you COULD ...
but what about script/generate ???
And is that so what he said about security?
--
2010 Mar 24
2
Mock "Consent_6335" received unexpected message :marked_for_destruction? with (no args)
I have a mock object (Person) that is associated with another object
(my_object) through a belongs_to association. When I check whether
my_object is valid (my_object.should be_valid), I am getting an error
like the following:
Mock "Person_6338" received unexpected
message :marked_for_destruction? with (no args)
Checking the list of methods on the mock,
2005 Dec 17
2
Storing an object in the db
I''ve asked this before, but never got a working response. I''d like to
store an object inside a binary field in my db. So I''d have a class
like this
class MyAwesomeClass
def do_something_awesome
...
end
end
then
class MyRecord < ActiveRecord::Base
end
the table my_record would have a binary field, my_object, that would
store an object of
2006 Jul 14
6
Get a collection through ActiveRecord for using with option_groups_from_collection_for_select
Hello,
I am having some difficulties with ActiveRecord.
What I want to do is to get a collection of SubjectGroups for using
with option_groups_from_collection_for_select
My Code:
========================================
class Subject < ActiveRecord::Base
has_and_belongs_to_many :users
belongs_to :subject_group
end
class SubjectGroup < ActiveRecord::Base
has_many :subjects
end
2007 Dec 06
2
R2HTML how to pair graphic.png and table
Dear list,
i have this problem:
how to pair a graphic.png and a table in R2HTML ?
The better showing of a mutiple analysis is sometimes to mate graphic and
table
Can anyone help me in this task ??
In the example below graphisc and table are subsequent and not pair..
directory=getwd()
myfile<-file.path(directory,"testHTML.html")
2017 Apr 01
2
Which doxygen doc should I look into?
Hi All,
I am going to clean up those doxygen links on LLVM Programmer’s
Manual [1], some are lost and some are too old.
However, I am confused on which doxygen link I should pick up. I see
there are mutiple links exist on LLVM web site
for LLVM classes. Take class Statistic as example, there are:
- http://llvm.org/doxygen/Statistic_8h-source.html (the oldest
one, I believe it's
2004 Feb 01
2
How do I provide redundancy and reliability w/ Asterisk?
I'm trying to set up an Asterisk system for a small office, and one thing
I haven't figured out yet is how to best provide reliability. One way
to go seems to be a T1 for all my incoming phone lines. What if that T1
goes down? Can I use mutiple POTS lines in conjuction with a T1, all
connecting to my Asterisk server?
What if my Asterisk server fails? Should I use two Asterisk servers,
2006 Aug 13
7
you can pass multiple parameters using link_to? anything bad
i just found out i can pass mutiple parameters from views like
<%= link_to doctype.name, :action => "show_towns", :id => doctype.name,
:id2 => doctype.id%>
silly me, i always had the impression that i could only pass 1. i guess
i dont have to use sessions after all for my site. is there anything
wrong with this?
basically instead of the user filling out
2007 Feb 02
0
Mutiple unique key(Compisitive unique)
Hi All..
I am new to ruby on rails.I want set the unquie on two fields.
Means in one model three fileds are there.
1.Id,
2.C-id
3.Q-id
I want set the unquie on C-Id,Q-Id combindely on the model validations
Can u give me advice?
I tryed with statemwnt validates_uniqueness_of [:c_id, :qid]
But it now giving the proper results
Regards,
Ramya
--
Posted via http://www.ruby-forum.com/.