$this->db2->query($sql,__LINE__,__FILE__);
if($this->db2->next_record()) {
$activity_list[$i]['name'] = $this->db2->f('name');
- $activity_list[$i]['code'] = $this->db2->f('code');
+ $activity_list[$i]['abbreviation'] = $this->db2->f('abbreviation');
}
$i++;
}
$this->db2->query($sql,__LINE__,__FILE__);
if($this->db2->next_record()) {
$this->t->set_var('name', $this->db2->f('name'));
- $this->t->set_var('code', $this->db2->f('code'));
+ $this->t->set_var('abbreviation', $this->db2->f('abbreviation'));
}
$this->t->set_var('lang_name','Assignment');
$this->t->set_var('lang_date','Date');
while ($this->db->next_record()) {
$assignments[$i]['assignment'] = $this->db->f('assignment');
$assignments[$i]['name'] = $this->db->f('name');
- $assignments[$i]['code'] = $this->db->f('code');
+ $assignments[$i]['abbreviation'] = $this->db->f('abbreviation');
$i++;
}
$this->t->set_block('assign_view_t','assign_view','list');
$this->t->set_var('lang_name','Assignment Name');
- $this->t->set_var('lang_code','Code');
+ $this->t->set_var('lang_code','Abbreviation');
$sql = "SELECT * FROM tc_assignment ORDER BY name ASC";
$this->db->query($sql,__LINE__,__FILE__);
while ($this->db->next_record()) {
$assignment_list[$i]['assignment'] = $this->db->f('assignment');
$assignment_list[$i]['name'] = $this->db->f('name');
- $assignment_list[$i]['code'] = $this->db->f('code');
+ $assignment_list[$i]['abbreviation'] = $this->db->f('abbreviation');
$i++;
}
for ($i=0; $i < count($assignment_list); $i++) {
$this->nextmatchs->template_alternate_row_color(&$this->t);
$this->t->set_var('name',$assignment_list[$i]['name']);
- $this->t->set_var('code',$assignment_list[$i]['code']);
+ $this->t->set_var('abbreviation',$assignment_list[$i]['abbreviation']);
$link_data['menuaction'] = 'tc.tc.assign_update';
$link_data['assignment'] = $assignment_list[$i]['assignment'];
if($action == 'save') {
$assignment['name'] = get_var('name',array('POST'));
- $assignment['code'] = get_var('code',array('POST'));
+ $assignment['abbreviation'] = get_var('abbreviation',array('POST'));
$this->db->query("UPDATE tc_assignment set " .
" name='" . $assignment['name'] . "'" .
- ", code='" . $assignment['code'] . "'" .
+ ", abbreviation='" . $assignment['abbreviation'] . "'" .
" WHERE assignment=" . $assignment['assignment'],__LINE__,__FILE__);
$this->assign_view();
if($action == 'insert') {
$assignment['name'] = get_var('name',array('POST'));
- $assignment['code'] = get_var('code',array('POST'));
- $this->db->query("INSERT INTO tc_assignment (name,code) " .
+ $assignment['abbreviation'] = get_var('abbreviation',array('POST'));
+ $this->db->query("INSERT INTO tc_assignment (name,abbreviation) " .
"VALUES ('" . $assignment['name'] . "','" .
- $assignment['code'] . "')",__LINE__,__FILE__);
+ $assignment['abbreviation'] . "')",__LINE__,__FILE__);
$this->assign_view();
return false;
}
if($action == 'add') {
$assignment['assignment'] = 0;
$this->t->set_var('name','');
- $this->t->set_var('code','');
+ $this->t->set_var('abbreviation','');
$this->t->set_var('lang_done','Cancel');
$this->t->set_var('lang_action','Adding New Assignment');
$this->t->set_var('actionurl',$GLOBALS['phpgw']->link('/tc/index.php','menuaction=tc.tc.assign_update&assignment=' .
$this->db->query($sql,__LINE__,__FILE__);
$this->db->next_record();
$this->t->set_var('name', $this->db->f('name'));
- $this->t->set_var('code', $this->db->f('code'));
+ $this->t->set_var('abbreviation', $this->db->f('abbreviation'));
$this->t->set_var('lang_done','Cancel');
$this->t->set_var('lang_action','Editing Assignment');
$this->t->set_var('actionurl',$GLOBALS['phpgw']->link('/tc/index.php','menuaction=tc.tc.assign_update&assignment=' .
while($this->db->next_record()) {
$assignment_list[$i]['assignment'] = $this->db->f('assignment');
$assignment_list[$i]['name'] = $this->db->f('name');
- $assignment_list[$i]['code'] = $this->db->f('code');
+ $assignment_list[$i]['abbreviation'] = $this->db->f('abbreviation');
$i++;
}
$total_width=$individual_width+$part_width;
for ($i=0; $i < count($assignment_list); $i++) {
$this->t->set_var('assignment_name',$assignment_list[$i]['name']);
- $this->t->set_var('assignment_code',$assignment_list[$i]['code']);
+ $this->t->set_var('assignment_abbreviation',$assignment_list[$i]['abbreviation']);
$this->t->fp('list1','header_list',True);
$total_width += $assignment_width;
}
while($this->db->next_record()) {
$assignment_list[$i]['assignment'] = $this->db->f('assignment');
$assignment_list[$i]['name'] = $this->db->f('name');
- $assignment_list[$i]['code'] = $this->db->f('code');
+ $assignment_list[$i]['abbreviation'] = $this->db->f('abbreviation');
$i++;
}
for ($i=0; $i < count($assignment_list); $i++) {
$this->t->set_var('assignment_name',$assignment_list[$i]['name']);
- $this->t->set_var('assignment_code',$assignment_list[$i]['code']);
+ $this->t->set_var('assignment_abbreviation',$assignment_list[$i]['abbreviation']);
$this->t->fp('list1','header_list',True);
$total_width += $assignment_width;
$total_willing[$i] = 0;
while ($this->db->next_record()) {
$assignment = $this->db->f('assignment');
$assignment_name = $this->db->f('name');
- $assignment_code = $this->db->f('code');
+ $assignment_abbreviation = $this->db->f('abbreviation');
$this->nextmatchs->template_alternate_row_color(&$this->t);
$table_data.="<tr bgcolor=". $this->t->get_var('tr_color') ."><td>$assignment_name</td>";
CREATE TABLE `tc_assignment` (
`assignment` int(12) unsigned NOT NULL auto_increment,
`name` varchar(60) NOT NULL,
- `code` varchar(12) default NULL,
+ `abbreviation` varchar(12) default NULL,
PRIMARY KEY (`assignment`)
) ENGINE=MyISAM AUTO_INCREMENT=11 DEFAULT CHARSET=latin1;
--
LOCK TABLES `tc_assignment` WRITE;
/*!40000 ALTER TABLE `tc_assignment` DISABLE KEYS */;
-INSERT INTO `tc_assignment` (`assignment`, `name`, `code`) VALUES (1,'Enrichment Night Babysitting','RS'),(2,'Building Lockup','LU'),(3,'Building Cleaning Coordinator','CC'),(4,'Missionary Splits','MS'),(5,'Stake Farm','SF'),(6,'Loveland Kitchen','LK'),(7,'Moves','MV'),(8,'Temple Kitchen & Laundary','TKL'),(9,'Temple Sealings','TS'),(10,'Temple Initatories','TI');
+INSERT INTO `tc_assignment` (`assignment`, `name`, `abbreviation`) VALUES (1,'Enrichment Night Babysitting','RS'),(2,'Building Lockup','LU'),(3,'Building Cleaning Coordinator','CC'),(4,'Missionary Splits','MS'),(5,'Stake Farm','SF'),(6,'Loveland Kitchen','LK'),(7,'Moves','MV'),(8,'Temple Kitchen & Laundary','TKL'),(9,'Temple Sealings','TS'),(10,'Temple Initatories','TI');
/*!40000 ALTER TABLE `tc_assignment` ENABLE KEYS */;
UNLOCK TABLES;