# HG changeset patch # User luisf # Date 1311602033 -3600 # Node ID 9302580058221e3b3ee96b73e9d3e66e8edd07de # Parent 1248a47e81b3488fa94e336c869771278ece1f36# Parent 8a26a0e291cff86560266c84ceab8d938474bba6 Merge from branch "luisf" diff -r 1248a47e81b3 -r 930258005822 app/models/ssamr_user_detail.rb --- a/app/models/ssamr_user_detail.rb Mon Jul 25 14:39:38 2011 +0100 +++ b/app/models/ssamr_user_detail.rb Mon Jul 25 14:53:53 2011 +0100 @@ -10,5 +10,15 @@ institution_id.blank? and other_institution.blank? end - + def institution_name() + if not self.institution_type.nil? + if self.institution_type + Institution.find(self.institution_id).name + else + self.other_institution + end + else + "" + end + end end