# -*coding:utf-8 -*-
class SetWorksCategories < ActiveRecord::Migration
  def up
    workscategory1 = WorksCategory.new
    workscategory1.category = "影音播放"
    workscategory1.save

    workscategory2 = WorksCategory.new
    workscategory2.category = "交通导航"
    workscategory2.save

    workscategory3 = WorksCategory.new
    workscategory3.category = "生活娱乐"
    workscategory3.save

    workscategory4 = WorksCategory.new
    workscategory4.category = "网络购物"
    workscategory4.save

    workscategory5 = WorksCategory.new
    workscategory5.category = "输入法"
    workscategory5.save

    workscategory6 = WorksCategory.new
    workscategory6.category = "聊天社区"
    workscategory6.save

    workscategory7 = WorksCategory.new
    workscategory7.category = "浏览器"
    workscategory7.save

    workscategory8 = WorksCategory.new
    workscategory8.category = "窗口小部件"
    workscategory8.save

    workscategory9 = WorksCategory.new
    workscategory9.category = "安全防护"
    workscategory9.save

    workscategory10 = WorksCategory.new
    workscategory10.category = "拍照摄影"
    workscategory10.save

    workscategory11 = WorksCategory.new
    workscategory11.category = "实用工具"
    workscategory11.save

    workscategory12 = WorksCategory.new
    workscategory12.category = "词典翻译"
    workscategory12.save

    workscategory13 = WorksCategory.new
    workscategory13.category = "教育阅读"
    workscategory13.save

    workscategory14 = WorksCategory.new
    workscategory14.category = "主题桌面"
    workscategory14.save

    workscategory15 = WorksCategory.new
    workscategory15.category = "事务管理"
    workscategory15.save

    workscategory16 = WorksCategory.new
    workscategory16.category = "系统工具"
    workscategory16.save

    workscategory17 = WorksCategory.new
    workscategory17.category = "资讯新闻"
    workscategory17.save

    workscategory18 = WorksCategory.new
    workscategory18.category = "金融理财"
    workscategory18.save

    workscategory19 = WorksCategory.new
    workscategory19.category = "通话通信"
    workscategory19.save

    workscategory20 = WorksCategory.new
    workscategory20.category = "电子办公"
    workscategory20.save

    workscategory21 = WorksCategory.new
    workscategory21.category = "体育竞技"
    workscategory21.save

    workscategory22 = WorksCategory.new
    workscategory22.category = "健康医疗"
    workscategory22.save
  end

  def down
    WorksCategory.all do |wc|
      wc.destroy
    end
  end
end
