1 class ConnectStory < ActiveRecord::Migration
9 st = Story.find(:first, :conditions => ['comic_id = ? and panel_id = ? and t = ?', c, s, t])
10 st = Story.new(:comic_id => c, :panel_id => s, :t => t) unless st
14 remove_column :comics, :editable
15 remove_column :panels, :comic_id
16 remove_column :panels, :t
17 add_column :panels, :publish, :integer, :null => false, :default => 0
21 add_column :comics, :editable, :integer, :null => false, :default => 0
22 add_column :panels, :comic_id, :integer, :null => false, :default => 0
23 add_column :panels, :t, :integer, :null => false, :default => 0
24 remove_column :panels, :publish
29 pn = Panel.find(i.panel_id)