Chris@0: class ExportPdf < ActiveRecord::Migration Chris@0: # model removed Chris@0: class Permission < ActiveRecord::Base; end Chris@0: Chris@0: def self.up Chris@0: Permission.create :controller => "projects", :action => "export_issues_pdf", :description => "label_export_pdf", :sort => 1002, :is_public => true, :mail_option => 0, :mail_enabled => 0 Chris@0: Permission.create :controller => "issues", :action => "export_pdf", :description => "label_export_pdf", :sort => 1015, :is_public => true, :mail_option => 0, :mail_enabled => 0 Chris@0: end Chris@0: Chris@0: def self.down Chris@1464: Permission.where("controller=? and action=?", 'projects', 'export_issues_pdf').first.destroy Chris@1464: Permission.where("controller=? and action=?", 'issues', 'export_pdf').first.destroy Chris@0: end Chris@0: end