Sha256: 215b1e434ae2925ca3bf1ccbf6c0acbc435fb170c6944c13d04ad6df66f53fee
Contents?: true
Size: 430 Bytes
Versions: 178
Compression:
Stored size: 430 Bytes
Contents
class AddPositionToCommons < ActiveRecord::Migration[5.2] def change add_column :educode_sales_permissions, :position, :integer EducodeSales::Permission.all.each_with_index do |d,index| if d.clazz == '销售态势' || d.clazz == '销售分工' || d.clazz == '商机管理' || d.clazz == '客户管理' d.update(position: index) else d.update(position: index * 10) end end end end
Version data entries
178 entries across 178 versions & 1 rubygems