update sheet number

This commit is contained in:
Nicolas Bally 2014-04-13 14:28:04 +02:00
parent 1e70d9e8cf
commit b1df467c45
2 changed files with 15 additions and 1 deletions

View File

@ -0,0 +1,14 @@
class UpdateSheetNumber < ActiveRecord::Migration
def self.up
Sheet.all.each do |s|
s.generate_sheet_number
s.save
end
end
def self.down
end
end

View File

@ -11,7 +11,7 @@
# #
# It's strongly recommended that you check this file into your version control system. # It's strongly recommended that you check this file into your version control system.
ActiveRecord::Schema.define(version: 20140410151036) do ActiveRecord::Schema.define(version: 20140413122412) do
create_table "admins", force: true do |t| create_table "admins", force: true do |t|
t.string "email", default: "", null: false t.string "email", default: "", null: false