Subversion Repositories VORC

Rev

Rev 65 | Rev 80 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 65 Rev 74
Line 89... Line 89...
89
      $FTS->{name}, $FTS->{coach}, $FTS->{date}, $FTS->{location}, $FTS->{start_time}, $FTS->{end_time}, $FTS->{capacity}, $FTS->{note}, $FTS->{id}
89
      $FTS->{name}, $FTS->{coach}, $FTS->{date}, $FTS->{location}, $FTS->{start_time}, $FTS->{end_time}, $FTS->{capacity}, $FTS->{note}, $FTS->{id}
90
    );
90
    );
91
    logit ($RCid, "$username updated class ($FTS->{id}, $FTS->{name}, $FTS->{date}, $FTS->{location}, $FTS->{start_time}, $FTS->{end_time}, $FTS->{capacity})");
91
    logit ($RCid, "$username updated class ($FTS->{id}, $FTS->{name}, $FTS->{date}, $FTS->{location}, $FTS->{start_time}, $FTS->{end_time}, $FTS->{capacity})");
Line 92... Line 92...
92
    
92
    
-
 
93
    # Update the volunteer shift for the coach too.
93
    # Update the volunteer shift for the coach too.
94
    if ($FTS->{classshiftid}) {
94
    $dbh->do (
95
      $dbh->do (
95
      "UPDATE shift
96
        "UPDATE shift
96
      SET date=?, location=?, start_time=?, end_time=?, note=?, assignee_id=?
97
        SET date=?, location=?, start_time=?, end_time=?, note=?, assignee_id=?
97
      WHERE id = ?",
98
        WHERE id = ?",
98
      undef,
99
        undef,
-
 
100
        $FTS->{date}, $FTS->{location}, $FTS->{start_time}, $FTS->{end_time}, $FTS->{name}, $FTS->{coach}, $FTS->{classshiftid}
-
 
101
      );
-
 
102
    } else {
-
 
103
      $dbh->do (
-
 
104
        "INSERT INTO shift
-
 
105
        (dept,role,type,date,location,start_time,end_time,doubletime,note,assignee_id)
-
 
106
        VALUES (?,?,?,?,?,?,?,?,?,?)",
-
 
107
        undef,
99
      $FTS->{date}, $FTS->{location}, $FTS->{start_time}, $FTS->{end_time}, $FTS->{name}, $FTS->{coach}, $FTS->{classshiftid}
108
        "COA", "Coach", "selected", $FTS->{date}, $FTS->{location}, $FTS->{start_time}, $FTS->{end_time}, 1, $FTS->{name}, $FTS->{coach}
100
    );
109
      );      
101
 
110
    }
Line 102... Line 111...
102
	}
111
	}
103
	
112
	
104
	$dbh->disconnect ();	 # stored into database successfully.
113
	$dbh->disconnect ();	 # stored into database successfully.