From 3f241aa189dacd37134c49231058abf868da4c03 Mon Sep 17 00:00:00 2001 From: Alan Pippin <apippin@pippins.net> Date: Sun, 3 Oct 2010 16:46:06 -0600 Subject: [PATCH] Fixed bug in not being able to select other interviewers in interviewer list --- inc/class.tc.inc.php | 11 ++++++----- templates/default/ppi_update.tpl | 2 +- 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/inc/class.tc.inc.php b/inc/class.tc.inc.php index 7dea317..26f8d7e 100644 --- a/inc/class.tc.inc.php +++ b/inc/class.tc.inc.php @@ -2457,15 +2457,16 @@ class tc $indiv = $this->db2->f('individual'); $interviewer_name = $this->db2->f('name'); if($indiv == $interviewer) { - $this->t->set_var('interviewer',$interviewer . ' selected'); + $this->t->set_var('interviewer',$indiv . ' selected'); } else { - $this->t->set_var('interviewer',$interviewer); + $this->t->set_var('interviewer',$indiv); } + #print "indiv: $indiv interviewer: $interviewer<br>"; $this->t->set_var('interviewer_name',$interviewer_name); $this->t->set_var('eqpresppi_checked','checked'); $this->t->fp('int_list','interviewer_list',True); } - + #print "selected interviewer: $interviewer<br>"; if($action == 'save') { $notes = get_var('notes',array('POST')); $this->db->query("UPDATE tc_interview set " . @@ -2782,9 +2783,9 @@ class tc $indiv = $this->db2->f('individual'); $interviewer_name = $this->db2->f('name'); if($indiv == $interviewer) { - $this->t->set_var('interviewer',$interviewer . ' selected'); + $this->t->set_var('interviewer',$indiv . ' selected'); } else { - $this->t->set_var('interviewer',$interviewer); + $this->t->set_var('interviewer',$indiv); } $this->t->set_var('interviewer_name',$interviewer_name); $this->t->fp('int_list','interviewer_list',True); diff --git a/templates/default/ppi_update.tpl b/templates/default/ppi_update.tpl index 80a8dc4..e8c6cb4 100644 --- a/templates/default/ppi_update.tpl +++ b/templates/default/ppi_update.tpl @@ -16,7 +16,7 @@ </tr> <tr> <td align="left"><font face="{font}"><b>Interviewer:</b> - <select name="interviewer"> + <select name="interviewer" {disabled}> <!-- BEGIN interviewer_list --> <option value={interviewer}>{interviewer_name}</option> <!-- END interviewer_list --> -- 2.34.1