Created
April 9, 2014 17:52
-
-
Save birnam/10296887 to your computer and use it in GitHub Desktop.
is this how to update a field in a migration that references other fields?
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public function up() | |
{ | |
$patientEvals = PatientEvaluation::all(); | |
foreach ($patientEvals as $eval) { | |
$eval->pfsh['social_history']['tobacco_use'] = | |
$eval->pfsh['social_history']['cigarette_use'] + ' - ' + | |
$eval->pfsh['social_history']['tobacco_use']; | |
$eval->save(); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment