2014-07-10 17:38:04 +08:00
|
|
|
# -*coding:utf-8 -*-
|
|
|
|
class CreateFirstPages < ActiveRecord::Migration
|
|
|
|
def change
|
|
|
|
create_table :first_pages do |t|
|
|
|
|
t.string :web_title
|
|
|
|
t.string :title
|
|
|
|
t.string :description
|
2014-07-14 11:28:29 +08:00
|
|
|
t.string :page_type
|
2014-07-10 17:38:04 +08:00
|
|
|
|
|
|
|
t.timestamps
|
|
|
|
end
|
2014-07-31 13:40:02 +08:00
|
|
|
|
2014-07-10 17:38:04 +08:00
|
|
|
fp = FirstPage.new
|
|
|
|
fp.web_title = "Trustie - 为大学生技术创新筑巢"
|
|
|
|
fp.title = "Trustie在线项目托管平台"
|
|
|
|
fp.description = "面向中国大学生与软件从业者,提供社交化的项目管理、代码托管、资源共享、合作交流。"
|
2014-07-14 11:28:29 +08:00
|
|
|
fp.page_type = "project"
|
|
|
|
|
2014-07-31 13:40:02 +08:00
|
|
|
fp.save(:validate => false)
|
2014-07-10 17:38:04 +08:00
|
|
|
end
|
|
|
|
end
|