Displaying 8 results from an estimated 8 matches for "menu_id".
Did you mean:
menu_idx
2006 Aug 03
3
HELP: multiple select list in ror
Hi
Search doesn''t seem to be working so my apologies if this has come up
before.
I have some simple code in a view that generates a multiple select:
<select name="menu_select" size="5" multiple="multiple">
<% for m in Menu.find(:all) %>
<!-- this needs to be abstracted in ror fashion -->
<option value="<%= m.id %>"
2006 Apr 07
0
Updating a relationship in a has_many and belongs_to
As the subjects suggests I''m trying to reiterate through certain pages,
assigning them to certain menus. My code is as follows
When I run the Below the position updates fine, but the menu_id in Page
doesn''t seem to change it all.
params["group_#{params[:id]}"].each_with_index do |id, position|
Page.update(id, :position => position + 1, :menu => menu)
end
When I run the Below it sometimes works but always says: You have a nil
object when you didn''t...
2012 Apr 02
0
active admin saving selection from collection_select and passing to controller
...and recipe are populated this page is to group the
recipe in a menu _menu_recipe.html.erb
<%= semantic_form_for [:admin, @menu_recipe] do |f| %>
<p>
<%= f.collection_select :recipe_id,
Recipe.all,:id,:name,:prompt => true%>
</p>
<p>
<%= f.collection_select :menu_id,
Menu.all,:id,:name,:prompt => true%>
</p>
<%= f.buttons :commit %>
<%end%>
when ever i try to catch the and create or group it, it comes with a
Couldn''t find Recipe without an ID error
my active admin controller which i override is
ActiveAdmin.register MenuReci...
2006 May 10
2
Ordering of subsets in a model.
Alright, I got this table with lots of entries for menus. There''s
several menus (with their own model since each menu got some special
information). Now, I want to be able to specify the order of the menu
entries inside the menu. acts_as_list seems to not quite do the trick
since it does ordering "globally" on the whole model and
acts_as_nested_set seems like overkill since
2003 Jul 18
1
Techfone VOIP phone
I ran across this company today and wondered if anyone was using their
phone:
http://www.techfone.com/
it's only $189 and has pretty good features for a VOIP phone although it's
only got H323 (no SIP support).
Has anyone seen these or is using one of these with Asterisk?
If not, I'm going to see if I can get one for testing.
MATT---
2012 Aug 25
0
accepts_nested_attributes_for and fields_for not working!
...Base
has_many :brunches, :dependent => :destroy
has_many :lunches, :dependent => :destroy
has_many :dinners, :dependent => :destroy
accepts_nested_attributes_for :lunches, :dinners, :brunches
end
Brunch, lunch, dinner models:
class Lunch < ActiveRecord::Base
attr_accessible :menu_id, :lunch_menu
belongs_to :menu
mount_uploader :lunch_menu, ImageUploader
end
Menu Form:
<%= form_for @menu, :html => {:multipart => true} do |f| %>
<% if @menu.errors.any? %>
<div id="error_explanation">
<h2><%= pluralize(@menu.errors.cou...
2006 Dec 24
0
[802] trunk/wxruby2/swig/classes: Add support for MenuEvent (MENU_OPEN, MENU_CLOSE, MENU_HIGHLIGHT)
...menu which is being opened or closed is a popup menu,
- if it is a normal one.
-
-This method should be only used with the and events.
-        */
-
- bool IsPopup() const;
</del><ins>+ wxMenuEvent(int id = 0, int menu_id = 0, wxMenu* menu = NULL);
+ wxMenu* GetMenu() const;
+ int GetMenuId() const;
+ bool IsPopup() const;
</ins><span class="cx"> };
</span><span class="cx">
</span><span class="cx">
</span></span></pre>
</d...
2006 Jul 07
9
Search on data accross many tables, linked by belongs_to
I am using Ferret and acts_as_ferret, as my search back-end for my Rails
project. I have a question about using acts_as_ferret on a main table
that is linked to other tables by foreign keys. Is there a way to
include the information linked by the belongs_to keyword in the search
results ?
As an example, let''s say I have a main table ''posts'':