echo "<h3>No id given!</h3>";
}
- $query = sprintf ("SELECT starttime,endtime,name,compound "
+ $query = sprintf ("SELECT starttime,endtime,name,compound,usage "
."FROM screw,compound "
."WHERE component = %d AND compound = id "
."ORDER BY starttime", $id);
}
printf ("<br>%s - %s: <a href=\"compound.php3?id=%d\">%s</a>",
$start[0], $end[0], $row['compound'], $row['name']);
+ if ($row['usage']) {
+ printf (" (%s)", $row['usage']);
+ }
}
}
?>
echo "<h3>No id given!</h3>";
}
- $query = sprintf ("SELECT component.name,component,screw.starttime,screw.endtime,types.name as type "
+ $query = sprintf ("SELECT component.name,component,screw.starttime,screw.endtime,types.name as type,usage "
."FROM screw,component,types "
."WHERE compound = %d AND component = component.id "
."AND screw.endtime IS NULL "
printf ("<br>%s <a href=\"component.php3?id=%d\">%s</a> since %s",
$row['type'], $row['component'], $row['name'], $start[0]);
}
+ if ($row['usage']) {
+ printf (" (%s)", $row['usage']);
+ }
}