Displaying 14 results from an estimated 14 matches similar to: "can i alter the _form.rhtml without have troubles to validat"
2006 Apr 28
7
a simple problem but difficult
how can i access to a collection that was created in the same control
and the data that a want to access isn?t the id
the collection has : id, usuario, comandancia
comandancia is the data to access
the question is how to access comandancia in @acceso
this code is wrong :
def new
@catelemento = Catelemento.new
@acceso= Catacceso.find(:all,
:conditions
2006 May 24
0
Problems validating form with collection_select
I have the following models:
class Comandancia < ActiveRecord::Base
has_many :elementos
end
class Elemento < ActiveRecord::Base
belongs_to :comandancia
validates_presence_of :nombre, :apellido_paterno, :apellido_materno,
:comandancia
end
In the view for New Elemento I''m using
<%= start_form_tag :action => ''create'' %>
<%= render :partial =>
2006 Aug 07
0
select da tabella in _form.rhtml
Ben trovati.
Ho questa _form :
<%= error_messages_for ''requirement'' %>
<!--[form:requirement]-->
<p><label for="requirement[structure_id]">Struttura</label><br/>
<%=
@structures = Structure.find(:all, :order => "nome").map {|f|
[f.nome,f.id] }
select(:structure, :id, @structures)
%>
<p><label
2006 Jun 20
2
Problem with "can''t dump anonymous class Class"
I submitted this earlier, but the web forums went down and I''ve screwed up
the thread, so I''m starting over.
I''m trying to built a document upload system. The system has a main
Document model with different subclasses for different types of documents.
With the code below, if I attempt to create a Document, it works fine, but
if I attempt to use one of the subclasses, I
2006 Feb 03
2
_form rendering question for adding multiple child objects
Hi
I have been following a thread here..
http://www.ruby-forum.com/topic/new?forum_id=3 but it did raise some new
curiosities that I hope someone can help address here :)
In particular it is with Duane''s super secret hack that works for
multiple child objects
> There''s a super-secret and mostly undocumented way of doing this
> that''s kind of handy, actually.
2006 Nov 23
1
loess lines in xyplot with two or more variables on the left side of a formula
Hello:
I recall something like this being discuss recently, but I can't seem
to locate an example in the archives. I have data like the following:
df <- expand.grid(1:4, 1992:2002)
names(df) <- c("MSA", "YEAR")
df$IDUPREV <- runif(44)
df$VALIDAT <- rnorm(44)
I want to create an xyplot() with separate loess lines for each series
(IDUPREV and VALIDAT) in
2008 Jan 08
3
What happened to _form.rhtml partial in rails 2.0??
Just wondering if anyone could point me to a good explanation of why
the latest way of doing things does not include using something like
_form.html.erb partials in RESTful rails 2.0?? Why did we move away
from partials, etc??
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To
2006 Jun 19
3
can''t dump anonymous class Class
I''m trying to create a document upload system, where most of the code is
the super class Document and just the path to file on the system is
controlled by the sub classes. When I attempt to use my code, I get the
following when I try to save the document.
can''t dump anonymous class Class
Any ideas?
** Migration **
class CreateDocuments < ActiveRecord::Migration
def
2006 Feb 27
8
Newbie question - Automatically update _form.rhtml?
Hi all, I''ve got an odd issue. I''m new to Ruby/Rails and have a bit of a
silly question. I''m following along with the nice little tutorial here,
to get an idea of the system:
http://www.onlamp.com/pub/a/onlamp/2005/01/20/rails.html?page=3
However, I''m running into an issue where the author adds a new field in
his database, refreshes the browser and shows
2007 Oct 23
1
Compute R2 and Q2 in PLS with pls.pcr package
Dear list
I am using the mvr function of the package pls.pcr to compute PLS
resgression using a X matrix of gene expression variables and a Y matrix
of medical varaibles.
I would like to obtain the R2 (sum of squares captured by the model) and
Q2 (proportion of total sum of squares captured in leave-one-out cross
validation) of the model.
I am not sure if there are specific slots in the
2004 Aug 27
1
predict.mvr error message
What version of R, what version of pls.pcr, and on what OS? Have you
checked whether your versions of software are up to date? I get:
> n <- 1350
> p <- 180
> y <- rnorm(n)
> x <- matrix(sample(0:1, n*p, replace=TRUE), n, p)
> fit <- mvr(x, y, method="SIMPLS", validat="none", ncomp=2)
> xt <- matrix(sample(0:1, 312*p, replace=TRUE), 312,
2009 Jul 04
9
prevent orphan records
If I have
belongs_to :user
Do I need to have
validates_presence_of :user_id
?
Does Rails validate the presence of :user_id automatically if I have
belongs_to :user?
In other words, does Rails prevent against creating orphan records that
belong to non-existent users?
Thanks.
--
Posted via http://www.ruby-forum.com/.
2006 Sep 20
3
Unit and Functional Tests Bombing with Ferret
Hello,
I am currently using ferret 0.9.5 and acts_as_ferret 0.2.3 on windows XP
All my unit and functions test that used to work before I installed
ferret are erroring out. My index is on a model name Post, and it looks
like all tests that contains methods which does CRUD to the Post model
bombs out.
Is there anything special I need to do before running unit and
functional test?
Thanks
2004 Aug 27
1
selecting unique columns of a matrix/data frame
Hi all,
I have a very high dimensional data and apparently there are several
columns that contain similar information (some columns are equal). I
want to form a matrix/data frame consisting of unique columns. Does
anyone have an efficient way of getting out these columns. A small
section of the data frame is given below.
Thanks for helping.
Stephen.
> newdata
[,1] [,2] [,3] [,4] [,5]