Actuatoren zijn de uitgangen van de robot, vergelijkbaar met onze benen en mond et cetera. Actuatoren brengen een robot tot leven. //SHOW ALL PARTS USED IN THIS GROUP ******************************************
// Location:/robotigs/includes/ list_parts_per_group.php
//This is an include, so no parsing needed
//LIST PARTS THAT BELONG TO THIS SORTS GROUP -----------------------------------
if ($koekje[0]>0 and $koekje[3]>0){ //User is logged in and translates
$qry="SELECT 1
, tblsystext.txlid
, tblsystext.txtname
, onderdelen.*
FROM onderdelen
INNER JOIN tblsystext ON onderdelen.partid = tblsystext.recordid
WHERE tblsystext.lanid = 1
AND tblsystext.txlid = 19
AND onderdelen.idsrtodd = $idsrt
ORDER BY tblsystext.txtname
;";
} else { //Else you are restricted to parts with status > 99 only
$qry="SELECT 1
, tblsystext.txlid
, tblsystext.txtname
, onderdelen.*
FROM onderdelen
INNER JOIN tblsystext ON onderdelen.partid = tblsystext.recordid
WHERE tblsystext.lanid = 1
AND tblsystext.txlid = 19
AND onderdelen.idsrtodd = $idsrt
AND onderdelen.status = 100
ORDER BY tblsystext.txtname
;";
}
$sql = pg_query($con1, $qry);
if (!$sql) {
echo "Er is een fout opgetreden.\n";
exit;
}
echo (" ");
echo ("");
echo ("Onderdelen in deze groep | ");
/*
echo ("");
echo ("");
echo ("Parts in this group | ");
if ($koekje[0]>0 and $koekje[3]>0){ //User is logged in and translates
echo ("Status | ");
}
echo (" ");
*/
$_recordteller = 0;
$_recordseinde = pg_num_rows($sql);
while ($_recordteller<$_recordseinde){
$ARR = pg_fetch_array ($sql ,$_recordteller);
$_id = $ARR[3];
$_status = $ARR[4];
$_createdby = $ARR[5];
$_createddate = $ARR[6];
$_changedby = $ARR[7];
$_changeddate = $ARR[8];
$_memo = $ARR[9];
$_producentnaamkort = $ARR[11];
$_urlproducent = $ARR[12];
$_type = $ARR[13];
$_urltype = $ARR[14];
$_leveranciernaamkort = $ARR[15];
$_urlleverancier = $ARR[16];
$_prijseurinclbtw = $ARR[17];
$_urlprijs = $ARR[18];
$_werkspanningvoltdc = $ARR[19];
$_stroomverbruikmax = $ARR[20];
$_opmerking = $ARR[21];
$_idsrtodd = $ARR[22];
$_urlodd = $ARR[23];
$prticon = $ARR[24];
$_oddnaam = get_txt($con1, 19, $koekje[2], $_id);
if ($ARR[29] == 1) {$imgname = "nederland.png";}
if ($ARR[29] == 2) {$imgname = "deutschland.png";}
if ($ARR[29] == 3) {$imgname = "uk.png";}
if ($ARR[29] == 4) {$imgname = "france.png";}
echo ("");
echo ("");
echo (" | ");
echo ("");
echo ("$ARR[2] | ");
if ($koekje[0]>0 and $koekje[3]>0){ //User is logged in and translates
echo ("");
$stat= get_status($con1, $koekje[2], $_status);
echo ("$stat | ");
}
//echo (" ");
//echo ("");
//echo (" | ");
echo (' ');
$_recordteller++;
} //endwhile
echo (' ');
//End of listing parts --------------------------------------------------------
////////////////////////////////////////////////////////////////////////////////
function get_status($conid, $lan, $defrec){
$qry = ("SELECT tblsystext.txtname
FROM tblsystext
LEFT JOIN status ON tblsystext.recordid = status.id
WHERE status.nr = $defrec
AND txlid = 61
AND lanid = $lan");
$result = pg_query($conid, $qry);
$row = pg_fetch_array($result);
return ("$row[0]");
}
?>
//This is an include, so no parsing needed
if ($koekje[0]>0 and $koekje[3]>0){ //User is logged in and translates
$qry=("SELECT soortonderdeel.*
FROM soortonderdeel
WHERE id = $idsrt
;");
$result = pg_query($con1, $qry);
while($row = pg_fetch_array($result)){ //Fields accesible by their name
foreach( $row AS $key => $val ){
$$key = stripslashes( $val );
}
}
$jaar = substr($changeddate,0,4);
$maand = substr($changeddate,5,2);
$dag = substr($changeddate,8,2);
$last_stamp = ("$dag $maand $jaar");
$jaar = substr($createddate,0,4);
$maand = substr($createddate,5,2);
$dag = substr($createddate,8,2);
$create_stamp = ("$dag $maand $jaar");
echo ("");
echo ("");
echo ("General information");
echo ("(");
echo ("edit)");
echo (" | ");
//*** LAST CHANGE MADE TO THIS SORT -----------------------------------------
echo ("Laatste wijziging   | ");
echo("$last_stamp | ");
//*** RECORD CREATED DATE ---------------------------------------------------
echo ("Aangemaakt   | ");
echo("$create_stamp | ");
// *** PART OWNER -----------------------------------------------------------
echo ("Eigenaar   | ");
$name = get_person_name($con1, $sort_master, $koekje[2]);
echo("$name | ");
//*** STATUS OF THIS ITEM
echo ("Status   | ");
$tmp = getStatTxt($con1, $status, $koekje[2]);
echo ("$tmp | ");
echo (" ");
}
?>
//Location:/robotigs/includes/ picts_show.php
// Requieres: $pict_list and several picture handling javascript routines
//*** FROM HERE ON THE PICTURE CORNER STARTS -----------------------------------
if ($pict_list){ //There are 1 or more pictures to be printed
echo (" | ");
$counter = 0;
$aantal = str_word_count($pict_list, 0, "0123456789");
$lijst = str_word_count($pict_list, 1, "0123456789");
while($counter < $aantal){
$pictkey = $lijst[$counter];
$qryy1 = ("SELECT *
FROM illustrations
WHERE ill_id = $pictkey
;");
$resulty1 = pg_query($con1, $qryy1);
while($row = pg_fetch_array($resulty1)){ //Fields accesible by their name
foreach( $row AS $key => $val ){
$$key = stripslashes( $val );
}
}
$image = ("/robotigs/documentatie/plaatjes/$ill_name");
$pictfull = str_replace('_small', '', $image); //Pictfull=biggest version
$alt = ("Just wait till your 57....");
$txtname = get_txt($con1, 18, $koekje[2], $ill_id); //Robot illustrations subtitles
echo ("");
echo (' ');
$nummer = $counter + 1;
$txtAfb = get_txt($con1, 9, $koekje[2], 3865); //Pic Afb
if ($koekje[0]>0 and $koekje[3]>0){ //User is logged in and translates
echo ("$txtAfb $nummer: ");
echo ("$txtname");
echo (" ");
echo ("Ontkoppelen ");
if ($counter==0){
echo ("Up ");
}else{
echo ("Up ");
}
if ($nummer == $aantal){
echo ("Down");
}else{
echo ("Down");
}
}else{ //Else of if Meaning the current useer is logged in
echo ("$txtAfb $nummer: $txtname");
}
echo (''); //End of this picture
$counter++; //Prepair for next picture
}
echo (' | '); //All pictures are printed
} //End of if there are 1 or more pictures to be printed ----------------------
?>