X-Git-Url: http://git.pippins.net/embedvideo/.git/static/images/x.gif?a=blobdiff_plain;f=inc%2Fclass.tc.inc.php;h=fd885ae33ab0b519bb1bea858d2021d2edd39dc4;hb=dac99ce35c9d3b885f7cc2584493812923303b3d;hp=79e286b6df9f23d9422c0e3d3153cffa9ad8cebd;hpb=fd3f70af9523a487a5b342501a39edad2e9b1080;p=eq%2F.git
diff --git a/inc/class.tc.inc.php b/inc/class.tc.inc.php
index 79e286b..fd885ae 100644
--- a/inc/class.tc.inc.php
+++ b/inc/class.tc.inc.php
@@ -290,7 +290,7 @@ class tc
$query_id = $this->db2->query($sql,__LINE__,__FILE__);
if($this->db2->num_rows($query_id) == 0) {
// We did not find any visits made by the currently assigned companionship,
- // look for visits made by any other companionship other than 0. (0 == EQ Presidency Visit)
+ // look for visits made by any other companionship other than 0. (0 == Presidency Visit)
$sql = "SELECT * FROM tc_visit WHERE date >= '$month_start' AND date <= '$month_end' ".
" AND companionship!=0".
" AND family=". $family_id;
@@ -492,7 +492,7 @@ class tc
$query_id = $this->db2->query($sql,__LINE__,__FILE__);
if($this->db2->num_rows($query_id) == 0) {
// We did not find any visits made by the currently assigned companionship,
- // look for visits made by any other companionship other than 0. (0 == EQ Presidency Visit)
+ // look for visits made by any other companionship other than 0. (0 == Presidency Visit)
$sql = "SELECT * FROM tc_visit WHERE date >= '$month_start' AND date <= '$month_end' ".
" AND companionship!=0".
" AND family=". $family_id;
@@ -1352,7 +1352,7 @@ class tc
$year = date('Y');
- // Get the EQ President
+ // Get the President
$sql = "SELECT * FROM tc_presidency where president=1 and valid=1";
$this->db->query($sql,__LINE__,__FILE__);
if($this->db->next_record()) {
@@ -1449,7 +1449,7 @@ class tc
$total_indivs=0; $indivs_with_yearly_ppi=0;
- // Display a scheduling table for the EQ President
+ // Display a scheduling table for the President
$table_data=""; $appt_table_data="";
$table_title = "District ".$district_number.": ".$district_name.": All indivs with Yearly PPI Not Completed";
$appt_table_title = "District ".$district_number.": ".$district_name.": Yearly PPI Appointment Slots";
@@ -1748,17 +1748,17 @@ class tc
}
// Save any changes made to the int notes table
- $new_data = get_var('int_notes',array('POST'));
+ $new_data = get_var('hti_notes',array('POST'));
foreach ($new_data as $entry) {
- $int_notes = $entry['notes'];
+ $hti_notes = $entry['notes'];
$indiv_id = $entry['indiv_id'];
$indiv_name = $entry['indiv_name'];
- $int_pri = $entry['pri'];
- //print "int_notes: $int_notes indiv_name: $indiv_name ";
+ $hti_pri = $entry['pri'];
+ //print "hti_notes: $hti_notes indiv_name: $indiv_name ";
// Perform database save actions here
$this->db->query("UPDATE tc_indiv set " .
- " int_notes='" . $int_notes . "'" .
- ",int_pri='" . $int_pri . "'" .
+ " hti_notes='" . $hti_notes . "'" .
+ ",hti_pri='" . $hti_pri . "'" .
" WHERE indiv=" . $indiv_id,__LINE__,__FILE__);
}
@@ -1902,14 +1902,14 @@ class tc
$indiv_id = $this->db2->f('indiv');
$indiv_name = $this->db2->f('name');
$indiv_phone[$indiv_id] = $this->db2->f('phone');
- $indiv_int_pri[$indiv_id] = $this->db2->f('int_pri');
- $indiv_int_notes[$indiv_id] = $this->db2->f('int_notes');
+ $indiv_hti_pri[$indiv_id] = $this->db2->f('hti_pri');
+ $indiv_hti_notes[$indiv_id] = $this->db2->f('hti_notes');
}
$id = $indiv_id;
$name = $indiv_name;
$phone = $indiv_phone[$id];
- $int_pri = $indiv_int_pri[$id];
- $int_notes = $indiv_int_notes[$id];
+ $hti_pri = $indiv_hti_pri[$id];
+ $hti_notes = $indiv_hti_notes[$id];
// If the companionship has already had its quarterly interview,
// Skip the other companion in the companionship.
@@ -1917,7 +1917,7 @@ class tc
$completed_data.= "
";
$appt_table_data = "";
- // Find out what the EQ Presidency ID is
- $sql = "SELECT * FROM tc_presidency where eqpres=1 and valid=1";
+ // Find out what the President ID is
+ $sql = "SELECT * FROM tc_presidency where president=1 and valid=1";
$this->db->query($sql,__LINE__,__FILE__);
if($this->db->next_record()) {
$presidency_name = $this->db->f('name');
@@ -3570,7 +3570,7 @@ class tc
$header_row.= "
Location
";
$table_data = "";
- $sql = "SELECT * FROM tc_presidency where valid=1";
+ $sql = "SELECT * FROM tc_presidency where valid=1 GROUP BY indiv ORDER BY name ASC";
$this->db->query($sql,__LINE__,__FILE__);
$i=0;
while ($this->db->next_record()) {
@@ -4070,13 +4070,10 @@ class tc
$president = $entry['president'];
$counselor = $entry['counselor'];
$secretary = $entry['secretary'];
- $eqpresidency = $entry['eqpresidency'];
- // Set the individual id to 0 for EQ Presidency tagged entry
- if($eqpresidency == 1) { $indiv="0"; }
- // Re-look up the individual name for the ID if we aren't an EQ Presidency tagged entry
- else { $name = $indiv2name[$indiv]; }
+ // look up the individual name for the ID
+ $name = $indiv2name[$indiv];
//print "id=$id indiv=$indiv name=$name email=$email district=$district president=$president ";
- //print "counselor=$counselor secretary=$secretary eqpres=$eqpresidency ";
+ //print "counselor=$counselor secretary=$secretary ";
if(($indiv > 0) || ($name != "")) {
if($id < $this->max_presidency_members) {
@@ -4089,15 +4086,14 @@ class tc
" ,president='" . $president . "'" .
" ,counselor='" . $counselor . "'" .
" ,secretary='" . $secretary . "'" .
- " ,eqpres='" . $eqpresidency . "'" .
" WHERE presidency=" . $id,__LINE__,__FILE__);
} else {
//print "Adding New Entry ";
$this->db2->query("INSERT INTO tc_presidency (presidency,indiv,district,name," .
- "email,president,counselor,secretary,eqpres,valid) " .
+ "email,president,counselor,secretary,valid) " .
"VALUES (NULL,'" . $indiv . "','" . $district . "','" .
$name . "','" . $email . "','" . $president . "','" .
- $counselor . "','" . $secretary . "','" . $eqpres . "','1'" .
+ $counselor . "','" . $secretary . "','1'" .
")",__LINE__,__FILE__);
}
} else {
@@ -4151,12 +4147,12 @@ class tc
$this->t->pfp('adminhandle','admin');
}
- // Now save off the data needed for an EQ Presidency Table Update
+ // Now save off the data needed for a Presidency Table Update
$sql = "SELECT * FROM tc_presidency where valid=1";
$this->db->query($sql,__LINE__,__FILE__);
$table_data = "";
- $header_row = "
Individual
Email
District
President
Counselor
Secretary
Presidency
";
+ $header_row = "
Individual
Email
District
President
Counselor
Secretary
";
while ($this->db->next_record()) {
// Extract the data for each presidency record
$id = $this->db->f('presidency');
@@ -4167,7 +4163,6 @@ class tc
$president = $this->db->f('president');
$counselor = $this->db->f('counselor');
$secretary = $this->db->f('secretary');
- $eqpresidency = $this->db->f('eqpres');
// Create the forms needed in the table
$table_data .= "