Displaying 3 results from an estimated 3 matches for "category3".
Did you mean:
category
2006 May 28
3
Working with topics and categories
...tiveRecord::Base
has_many :categories
end
class Category < ActiveRecord::Base
belongs_to :topic
end
I need page structure like this:
<h3>Topic1</h3> (id = 1)
<ul><li>Category1</li> (topic_id = 1)
<li>Category2</li> (topic_id = 1)
<li>Category3</li> (topic_id = 1)
<li>Category4</li></ul> (topic_id = 1)
<h3>Topic2</h3> (id = 2)
<ul><li>Category1</li> (topic_id = 2)
<li>Category2</li> (topic_id = 2)
<li>Category3</li> (topic_id = 2)
<li>Cat...
2008 Apr 01
1
Navigation Problems
Hi,
I am having problems with my page. I have a banner and navigation bar in
controller_name.rhtml in app/views/layout. Can someone please help?
Thanks
In the navigation bar, I have the following links:
Category1
Sub-Category1
Sub-Category2
Sub-Category3
Sub-Category4
Sub-Category5
Sub-Category6
In the main content, I have the following links:
Sub-Category1 edit delete
Sub-Category2 edit delete
Sub-Category3 edit delete
Sub-Category4 edit delete
Sub-Category5 edit delete
Sub-Category6 edi...
2008 Nov 14
3
migration with data
...gory.create(:name => name)}
end
def self.down
NAMES.each{|name| Category.find_by_name(name).destroy}
end
end
My problem is if I seperately done these migrations ie one by one
everything is ok .I get sequence starts with 100 and the values like
100 Category1
101 Category2
102 Category3
But if I just migrate two migrations at once I get error
-- execute("ALTER SEQUENCE categories_id_seq RESTART WITH 100;")
rake aborted!
RuntimeError: ERROR C42P01 Mrelation "categories_id_seq" does not
exist Fnamespace.c L273 RRangeVarGetRelid: ALTER SEQUE...