Sha256: b5534987cbc70239abe9ca75f86d0282587ed55619a2424d163c280b02736274

Contents?: true

Size: 231 Bytes

Versions: 1

Compression:

Stored size: 231 Bytes

Contents

class UpdateQuadros < ActiveRecord::Migration
  def up
  	Quadro.where("tipo_diabete_id IS NOT NULL").each do |q|
  		q.update_attributes(:hipotese_diagnostica => q.tipo_diabete.nome)
  		q.save!
  	end
  end

  def down
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
omniauth-sabia-1.0.1 db/migrate/20140618124311_update_quadros.rb