Displaying 20 results from an estimated 2603 matches for "recipes".
Did you mean:
recipe
2006 Jun 18
6
integer array columns
Postgres database.
I have a categories table, with two columns id, and name.
I have a recipes table, with a category_ids column.
I want each recipe to belong to one or more category.
in recipe_controller.rb I have this:
def create
@recipe = Recipe.new( @params[''recipe''] )
@recipe.category_ids = @params[''recipe''][''category_ids''].map{...
2006 Nov 17
8
Basic search, quick question
...ve checked
and none seem to help my problem.
I''m trying to get a simple search to work on my Rails app, but I get a
"Couldn''t find Recipe without an ID" error when I search. Here''s what I
have:
list.rhtml
<%= start_form_tag :action => ''find_recipes'' %>
<input type="text" name="search" />
<%= submit_tag ''Search'' %>
<%= end_form_tag %>
recipes_controller.rb
def find_recipes
@recipe = Recipe.find :all, :conditions => [''title LIKE ?'',
"%#{pa...
2006 May 11
3
undefined??
...part1 I
(already) encountered the first complication.
After doing those basic actions to set up the basic site, the tutorial
tells me to overwrite the "list" method included in the "scaffold
:recipe" method which we find in the recipe controller with this code:
def list
@recipes = recipe.find_all
end
Now this code doesn''t work. When trying to view my site I keep getting
an error message which says that the variable recipe is undefined.
With the (average) knowledge I own concerning programming I suppose
"@recipes" should define the variable, which does...
2006 Jul 08
2
NoMethodError in Recipe#index
...d doing the infamous
Cookbook as a starting point. I''m all set until the point when I go to
create of sumbit my recipe and I get this error:
NoMethodError in Recipe#index
You have a nil object when you didn''t expect it!
The error occured while evaluating nil.name
15: <% @recipes.each do |recipe| %>
16: <tr>
17: <td><%= link_to recipe.title, :action => "show", :id => recipe.id
%></td>
18: <td><%= recipe.category.name %></td>
19: <td><%= recipe.date %></td>
20: </tr>
21: <%...
2006 May 07
6
RuntimeError in Recipe#edit
I have tried to learn ruby on rails from scratch by going into a
tutorial at the following website.
http://instantrails.rubyforge.org/tutorial/index.html
I followed the suggestions and encountered 3 problems so far.
1. Couldn''t start the Apache server. Error message "Port 80 was used by
some other process." I over-came the problem by going
into configuration and change the
2006 Mar 29
11
why belongs_to does not like validation?
This works :
class Recipe < ActiveRecord::Base
belongs_to :category
end
But (when I add validation) this does not work :
class Recipe < ActiveRecord::Base
belongs_to :category
validates_length_of :category, :within => 6..20
validates_uniqueness_of :category, :message => "already exists"
end
thank you
--
View this message in context:
2006 Jul 30
8
Method_missing from Ruby for Rails book
I''m having a problem getting this example from the book to work:
class Cookbook
attr_accessor :title, :author
def initialize
@recipes = []
end
def method_missing(m, *args, &block)
@recipes.send(m, *args, &block)
end
end
cb = Cookbook.new
cb << recipe_for_cake
cb << recipe_for_chicken
beef_dishes = cb.find_all {|recipes| recipe.main_ingredient == "beef" }
I''m getting callable.rb:...
2011 Jul 30
1
[PATCH node] Update rawhide to F17
Also add kickstarts for F17
Signed-off-by: Mike Burns <mburns at redhat.com>
---
recipe/Makefile.am | 2 +-
recipe/ovirt17-install.ks | 1 +
recipe/ovirt17-minimizer.ks | 1 +
recipe/ovirt17-pkgs.ks | 1 +
recipe/ovirt17-post.ks | 1 +
5 files changed, 5 insertions(+), 1 deletions(-)
create mode 120000 recipe/ovirt17-install.ks
create mode 120000
2006 Jan 03
4
validates_presence_of *_id attributes
Hi all,
I am a newbie to Rails. Please enlighten me on how to do this
appropriately, the Rails and the Ruby way:
Suppose I have a Recipe model. Let''s simplify things and pretend that
it has only 2 attributes, a :name and the other is a ''category_id''. In
the recipes table, category_id is a foreign key to field id of table
categories.
We also assume that I have generate the appropriate scaffolding code
for Recipe and Category. All goes well if I go to
http://localhost:3000/categories (I''m using WEBrick) and add a new
Category and then go to http://loc...
2011 Jul 25
0
[PATCH node] Drop F15 build recipes
Due to a critical dracut bug, and a strong dev focus on F16, we're
dropping all F15 recipes.
Signed-off-by: Mike Burns <mburns at redhat.com>
---
recipe/ovirt15-install.ks | 1 -
recipe/ovirt15-minimizer.ks | 1 -
recipe/ovirt15-pkgs.ks | 2 -
recipe/ovirt15-post.ks | 145 ------------------------------------------
recipe/ovirt16-install.ks | 2 +-
recip...
2006 May 07
6
Unable to get past Tutorial 1 in RubyOnRails
...k2? and used the MySQL-Front 3.2 to
create a new database ?cookbook2? and check to make sure that the tables
and fields resembled those of the pre-installed ?cookbook?.
I was able to log into the website to create the required categories so
that they wouldn?t be empty when I tried to create new recipes.
Some one please help!
I was able to to enter the website to create a new recipe, using
http://localhost:3000/recipe/new
Problem came when I pressed to ?Create? button.
This brought me to the url: http://localhost:3000/recipe/list
Error message:
NoMethodError in Recipe#list
Showing app/views/...
2006 May 24
6
newbie question: missing template
Hi
I''m new to this forum and new to Rails so excuse me if this is a daft
question.
I''m following the ONLamp.com tuturial and all has been well untill
changing the template for the recipes. I have followed the instructions
and added this code to the controller:
class RecipeController < ApplicationController
scaffold :recipe
def list
@recipes = Recipe.find_all
end
end
I have also created the list.rhtml file to the
C:\rails\cookbook\app\views\recipe directory using the htm...
2006 Jan 06
3
Cookbook recipes eg - ordering categories in the recipe pull-down box
People,
I can order categories when looking at the categories list page but how
do I change the recipe page to list the categories in alpha order in the
recipe pull-down box?:
> <p><b>Category:</b><br>
> <select name="recipe[category_id]">
> <% @categories.each do |category| %>
> <option value="<%= category.id
2005 Sep 25
7
(newbie) Missing Template Error using Rolling With Rails Tutorials
Hi all,
New to the list, Ruby, & RoR. I''ve been going through the Rolling
With Rails tutorial, but am getting the following error when the
instructions tell you to add the @recipes = Recipe.find_all line to
the RecipeController:
Template is missing
Missing template ./script/../config/..//app/views//recipe/index.rhtml
The index.rhtml file is right where it''s supposed to be, and the code
is correct (as far as I can tell, I even used the downloadable version
of the...
2007 Sep 27
5
New R website: R-Cookbook.com
R Community,
I've put together a website that I thought this mailing list might be
interested in: http://www.r-cookbook.com
It's a (free) community-driven content management system for R
"recipes", or working examples. Some of the features of the site are
code highlighting, recipe ratings, recipe comments, personal "recipe
boxes" to save your favorite recipes, community tagging, RSS feeds
for each user and for each tag, and similar recipe recommendations.
Although I i...
2010 Mar 15
1
[PATCH node] fix reboot hang on /etc
---
recipe/common-pkgs.ks | 1 +
recipe/common-post.ks | 15 +++++++++++++++
2 files changed, 16 insertions(+), 0 deletions(-)
diff --git a/recipe/common-pkgs.ks b/recipe/common-pkgs.ks
index 3aafe53..bc96b43 100644
--- a/recipe/common-pkgs.ks
+++ b/recipe/common-pkgs.ks
@@ -76,3 +76,4 @@ acpid
device-mapper-multipath
kpartx
dracut-network
+patch
diff --git a/recipe/common-post.ks
2005 Mar 06
2
Recipe Browser 0.4.1
I am please to announce the release of Recipe Browser 0.4.1. This
project (and files) can be located at
http://rubyforge.org/projects/recipe/.
This release brings Recipe Browser up to Rails 0.10, with a handful of
bug fixes. Special thanks to E Gard (x2egard) the newest member to
the project who also happened to do all the work for this release ;).
We would love to hear any questions,
2006 Feb 06
35
ROR Recipes Beta
Yesterday I got the beta version of ROR recipes book and the recipes are great. For those of you still thinking about it, I highly recommend the book.
The only thing I wish is that if there were some more recipes (greedy me), especially AJAX related and installing an application within your current application.
For instance, it wil...
2010 Apr 07
1
[PATCH node] Fix defaulting of OVIRT_CACHE_DIR in recipe makefile
Due to a typo, the defaulting of OVIRT_CACHE_DIR in the recipe
Makefile.am was broken.
Signed-off-by: Mike Burns <mburns at redhat.com>
---
recipe/Makefile.am | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/recipe/Makefile.am b/recipe/Makefile.am
index fb34437..d09905a 100644
--- a/recipe/Makefile.am
+++ b/recipe/Makefile.am
@@ -27,7 +27,7 @@ ARCH =
2010 Apr 13
1
[PATCH node] refactor node image recipe
top-level kickstart file contains only includes,
example custom-template.ks is provided with documented customization
points.
Signed-off-by: Alan Pevec <apevec at redhat.com>
---
recipe/common-manifest-post.ks | 31 +++++++++++
recipe/common-manifest-pre.ks | 11 ++++
recipe/common-post-chroot.ks | 46 ++++++++++++++++
recipe/common-post.ks | 24 +++++++++