"?>
Datum sorteren op datum
Type sorteren op type
Project sorteren op projectnummer
Omschrijving Status Pdf








© Calduran
3"; else $l_strSql = "SELECT lID, dtAanmaakDatum, sType, lTypeID, sProjectNr, sOmschrijving, lStatusID, dtDatum, Password(lTypeID) as sCode, sPdf FROM overzicht WHERE lLoginID = " . $_SESSION['LoggedIn']['lID']; if($l_intStatus > 0) $l_strSql .= " AND lStatusID = " . $l_intStatus; $l_strSql .= " AND (dtAanmaakDatum BETWEEN '" . substr($l_strStartDate,6,4) . "-" . substr($l_strStartDate,3,2) . "-" . substr($l_strStartDate,0,2) . "' AND '" . substr($l_strEndDate,6,4) . "-" . substr($l_strEndDate,3,2) . "-" . substr($l_strEndDate,0,2) . "')"; $l_strSql .= " ORDER BY $l_strColumn $l_strOrder"; $l_objRS = mysql_query($l_strSql); //echo ""; if(mysql_num_rows($l_objRS)){ while($l_objRSdata = mysql_fetch_array($l_objRS)){ if(ProjectVoorbereider($l_objRSdata['lTypeID'], $l_strPjvb, $l_objRSdata['sType'])){ ?> "?> )"> )"> )"> )"> )"> \"\""?> Er zijn geen digitale documenten gevonden"; } function getStatus($v_lngID, $v_dtDate){ $l_strSql = "SELECT lID, sName FROM status WHERE lID = $v_lngID"; $l_objRS = mysql_query($l_strSql); $l_strTemp = ""; if(mysql_num_rows($l_objRS)){ $l_objRSdata = mysql_fetch_array($l_objRS); $l_strTemp = $l_objRSdata['sName']; if($v_dtDate != "" && $v_dtDate != "0000-00-00") $l_strTemp .= " (" . showDate($v_dtDate) . ")"; } return $l_strTemp; } function ProjectVoorbereider($v_lngVbsID, $v_strPjvb, $v_strType){ if($v_strType == "voorbereidingsschema") $l_strSql = "SELECT lID FROM voorbereidingsschema WHERE lID = $v_lngVbsID"; else if($v_strType == "vbsnl" || $v_strType == "vbsnl1" || $v_strType == "vbsnlv2") $l_strSql = "SELECT lID FROM vbsnl WHERE lID = $v_lngVbsID"; else if($v_strType == "vbsbe") $l_strSql = "SELECT lID FROM vbsbe WHERE lID = $v_lngVbsID"; else if($v_strType == "vbsfr") $l_strSql = "SELECT lID FROM vbsfr WHERE lID = $v_lngVbsID"; else if($v_strType == "vbsde" || $v_strType == "vbsde1") $l_strSql = "SELECT lID FROM vbsde WHERE lID = $v_lngVbsID"; else $l_strSql = "SELECT lID FROM voorbereidingsschema_duits WHERE lID = $v_lngVbsID"; if($v_strPjvb != "") $l_strSql .= " AND sPvbNaam = '" .$v_strPjvb . "'"; $l_objRS = mysql_query($l_strSql); if(mysql_num_rows($l_objRS)){ $l_objRSdata = mysql_fetch_array($l_objRS); return true; } return false; } function deleteData(){ $l_arrItems = $_POST['deleteProject']; $l_arrIDs = implode(",", $l_arrItems); $l_strSql = "SELECT lID, lTypeID, sType FROM overzicht WHERE lID IN($l_arrIDs)"; $l_objRS = mysql_query($l_strSql); if(mysql_num_rows($l_objRS)){ while($l_objRSdata = mysql_fetch_array($l_objRS)){ deleteAttachments($l_objRSdata['lTypeID'], $l_objRSdata['sType']); deleteProject($l_objRSdata['lTypeID'], $l_objRSdata['sType']); } $l_strSql = "DELETE FROM overzicht WHERE lID IN($l_arrIDs)"; mysql_query($l_strSql); } } function deleteAttachments($v_lngProjectID, $v_strType){ if($v_strType == "vorbereitungsplan") $v_strType = "voorbereidingsschema_duits"; $l_strSql = "SELECT lID, sFilename FROM " . $v_strType . "_uploads WHERE lVbsID = $v_lngProjectID"; $l_objRS = mysql_query($l_strSql); if(mysql_num_rows($l_objRS)){ while($l_objRSdata = mysql_fetch_array($l_objRS)){ unlink($v_strType . "/assets/" . $l_objRSdata['sFilename']); } } $l_strSql = "DELETE FROM " . $v_strType . "_uploads WHERE lVbsID = $v_lngProjectID"; mysql_query($l_strSql); } function deleteProject($v_lngProjectID, $v_strType){ $l_strSql = "DELETE FROM " . $v_strType . "_levering WHERE lVbsID = $v_lngProjectID"; mysql_query($l_strSql); $l_strSql = "DELETE FROM " . $v_strType . " WHERE lID = $v_lngProjectID"; mysql_query($l_strSql); } function loadFilterValues(&$v_intStatus, &$v_strPjvb, &$v_strStartDate, &$v_strColumn, &$v_strOrder){ $l_strSql = "SELECT lID, iStatus, sPjvb, dtStartDate, sColumn, sOrder FROM filter WHERE lLoginID = " . $_SESSION['LoggedIn']['lID']; $l_objRS = mysql_query($l_strSql); if(mysql_num_rows($l_objRS)){ $l_objRSdata = mysql_fetch_array($l_objRS); $v_intStatus = $l_objRSdata['iStatus']; $v_strPjvb = $l_objRSdata['sPjvb']; $v_strStartDate = substr($l_objRSdata['dtStartDate'],8,2) . "-" . substr($l_objRSdata['dtStartDate'],5,2) . "-" . substr($l_objRSdata['dtStartDate'],0,4); $v_strColumn = $l_objRSdata['sColumn']; $v_strOrder = $l_objRSdata['sOrder']; } } function saveFilterValues(){ global $l_intStatus, $l_strPjvb, $l_strColumn, $l_strOrder, $l_strStartDate; $dtStartDate = substr($l_strStartDate,6,4) . "-" . substr($l_strStartDate,3,2) . "-" . substr($l_strStartDate,0,2); $l_strSql = "UPDATE filter SET iStatus = $l_intStatus, sPjvb = '$l_strPjvb', sColumn = '$l_strColumn', sOrder = '$l_strOrder', dtStartDate = '$dtStartDate' WHERE lLoginID = " . $_SESSION['LoggedIn']['lID']; mysql_query($l_strSql); } ?>