Current File : /home/inlingua/www/noida/icentex/iNDEED/timesheet_user.form_old_2_4_18.php |
<?php include("header_indeed.php"); ?>
<?php
echo "<h3>".$succFailMesg."</h3>";
?>
<?php
// Copyright, Panalink Infotech Limited. Created on: 22-05-2010
// Include header
// Show result of a form submission?
if ($showResult == "Y")
{
header("Location:timesheet_user.select.php?offset=".$_REQUEST[offset]."");
//echo "<br><a href='timesheet_user.select.php?offset=".$_REQUEST[offset]."'>Back</a><br>";
// Include footer
//include "footer.php";
return;
}
?> <script language="javascript">
<!--
function validate(form)
{ if (document.form.recNo.value=="")
{ alert("recNo cannot be blank. Please enter it.");
document.form.recNo.focus(); return false;
}
if (document.form.name.value=="")
{ alert("Name cannot be blank. Please enter it.");
document.form.name.focus(); return false;
}
if (document.form.username.value=="")
{ alert("User Name cannot be blank. Please enter it.");
document.form.username.focus(); return false;
}
if (document.form.password.value=="")
{ alert("Password cannot be blank. Please enter it.");
document.form.password.focus(); return false;
}
// Perform basic checks on email address
if (document.form.email.value != "")
{
var reg = /^([A-Za-z0-9_\-\.])+\@([A-Za-z0-9_\-\.])+\.([A-Za-z]{2,4})$/;
var address = document.form.email.value;
if(reg.test(address) == false) {
alert('Invalid Email Address');
document.form.email.focus();
return false;
}
}
else
{ alert("Email address cannot be blank. Please enter it.");
document.form.email.focus(); return false;
}
if (document.form.contact_no.value=="")
{ alert("Contact No. cannot be blank. Please enter it.");
document.form.contact_no.focus(); return false;
}
if (document.form.startingHours.value=="")
{ alert("Starting Hours cannot be blank. Please enter it.");
document.form.startingHours.focus(); return false;
}
if (document.form.rates_designation.value=="")
{ alert("Rates Apply cannot be blank. Please enter it.");
document.form.rates_designation.focus(); return false;
}
return true;
}
function isNumberKey1(evt)
{
var charCode = (evt.which) ? evt.which : event.keyCode
if (charCode >=48 && charCode <=57)
{
return true;
}
else if(charCode==46 || charCode==8)
{
return true;
}
else
{
return false;
}
}
-->
</script>
<script type="text/javascript" src="js/student.js"></script>
<style>
#target { padding: 5px; border: 1px solid #000; width:200px; display:none;}
#target_mon { padding: 5px; border: 1px solid #000; width:200px; display:none;}
#target_tue { padding: 5px; border: 1px solid #000; width:200px; display:none;}
#target_wed { padding: 5px; border: 1px solid #000; width:200px; display:none;}
#target_thu { padding: 5px; border: 1px solid #000; width:200px; display:none;}
#target_fri { padding: 5px; border: 1px solid #000; width:200px; display:none;}
#target_sat { padding: 5px; border: 1px solid #000; width:200px; display:none;}
#target_sun { padding: 5px; border: 1px solid #000; width:200px; display:none;}
#content1 ul {
list-style: none;
}
</style>
<form method='post' action='timesheet_user.main.php' name="form" onsubmit="return validate(this)">
<input type='hidden' name='recNo' value="<?php echo $dbObject->getDbField('recNo');?>">
<input type='hidden' name='kV' value="<?php echo $_REQUEST['kV'];?>">
<input type='hidden' name='offset' value="<?php echo $_REQUEST[offset] ?>">
<table boder='1' class='pa-nor'>
<tr valign='top'><td>Type</td><td>
<select name="usertype">
<option value="user" <?php if($dbObject->getDbField('usertype')=="user") echo"selected"; ?> >Teaching services</option>
<!--<option value="Teaching Services Staff" <?php if($dbObject->getDbField('usertype')=="Teaching Services Staff") echo"selected"; ?> >Teaching Services Staff</option>-->
<option value="FD" <?php if($dbObject->getDbField('usertype')=="FD") echo"selected"; ?> >Customer services</option>
<option value="Business Assets" <?php if($dbObject->getDbField('usertype')=="Business Assets") echo"selected"; ?> >Business Assets</option>
<option value="Administration and Accounts" <?php if($dbObject->getDbField('usertype')=="Administration and Accounts") echo"selected"; ?> >Administration and Accounts</option>
<option value="Other" <?php if($dbObject->getDbField('usertype')=="Other") echo"selected"; ?> >Other</option>
</select>
</td></tr>
<tr valign='top'><td>Name</td><td><input type='text' name='name' value="<?php echo $dbObject->getDbField('name');?>" size='20' maxlength='30'></td></tr>
<tr><td>Date Of Birth</td><td><input type="text" name="dob" id="dob" value="<?php echo $dbObject->getDbField('dob');?>" /></td></tr>
<?php
if($currentMode=='Add')
{
?>
<tr valign='top'><td>Username(EmpId)</td><td><input type='text' name='username' value="<?php echo $dbObject->getDbField('username');?>" size='20' maxlength='250'></td></tr>
<tr valign='top'><td>Password</td><td><input type='text' name='password' value="welcome" size='20' maxlength='250' ></td></tr>
<?php
}
else
{
?>
<tr valign='top'><td>Username(EmpId)</td><td><input type='text' name='username' value="<?php echo $dbObject->getDbField('username');?>" size='20' maxlength='250'></td></tr>
<tr valign='top'><td>Password</td><td><input type='password' name='password' value="<?php echo $dbObject->getDbField('password');?>" size='20' maxlength='250' readonly></td></tr>
<?php } ?>
<tr valign='top'><td>Email</td><td><input type='text' name='email' value="<?php echo $dbObject->getDbField('email');?>" size='20' maxlength='250'></td></tr>
<tr valign='top'><td>Conveyance Email</td><td><input type='text' name='conveyance_email' value="<?php echo $dbObject->getDbField('conveyance_email');?>" size='40' maxlength='400'></td></tr>
<tr valign='top'><td>Mobile</td><td><input type='text' name='contact_no' value="<?php echo $dbObject->getDbField('contact_no');?>" size='10' maxlength='200' onkeypress="return isNumberKey1(event)"></td></tr>
<tr valign='top'><td>Landline</td><td><input type='text' name='landline' value="<?php echo $dbObject->getDbField('landline');?>" size='10' maxlength='200' onkeypress="return isNumberKey1(event)"></td></tr>
<?php
$house= new dbHandler();
$house->connect();
$query_house="select recNo, house from ingl_houses order by house ";
$result_house=$house->select($query_house);
$house_array=array();
while($data_house=$house->SelectNext($result_house))
{
$house_array[''.$data_house[recNo].'']=$data_house['house'];
}
$house_selected=$dbObject->getDbField('house');
$house_extra='style="width:150px;"';
?>
<tr><td>House</td><td><?php echo select_drop($house_array,'house','Select House','0',$house_selected,$house_extra); ?></td></tr>
<tr valign='top'><td>Starting Hours</td><td><input type='text' name='startingHours' value="<?php echo $dbObject->getDbField('startingHours');?>" size='20' maxlength='200' onkeypress="return isNumberKey1(event)"></td></tr>
<tr valign='top'><td>Primary Center</td><td>
<?php
$queryloc="select * from timesheet_location order by location";
$resultloc=mysqli_query($conn,$queryloc) or die(mysqli_query($conn,));
?>
<select name='primarycenter'>
<?php
while($num=mysqli_fetch_array($resultloc))
{
if($num[location]=="S.Extn")
{
echo"<option value='".$num[location]."' ";
if($dbObject->getDbField('primarycenter')==$num[location])
{
echo"selected";
}
echo">South Extension</option>";
}
else
{
echo"<option value='".$num[location]."' ";
if($dbObject->getDbField('primarycenter')==$num[location])
{
echo"selected";
}
echo">".$num[location]."</option>";
}
}
?>
</select>
<!--<input type='text' name='primarycenter' value="<?php echo $dbObject->getDbField('primarycenter');?>" size='20' maxlength='200'>--></td></tr>
<tr valign='top'><td>Secondary Center</td><td>
<?php
$queryloc="select * from timesheet_location order by location";
$resultloc=mysqli_query($conn,$queryloc) or die(mysqli_query($conn,));
?>
<select name='secondarycenter'>
<?php
while($num=mysqli_fetch_array($resultloc))
{
if($num[location]=="S.Extn")
{
echo"<option value='".$num[location]."' ";
if($dbObject->getDbField('secondarycenter')==$num[location])
{
echo"selected";
}
echo">South Extension</option>";
}
else
{
echo"<option value='".$num[location]."' ";
if($dbObject->getDbField('secondarycenter')==$num[location])
{
echo"selected";
}
echo">".$num[location]."</option>";
}
}
?>
</select>
<!--<input type='text' name='primarycenter' value="<?php echo $dbObject->getDbField('primarycenter');?>" size='20' maxlength='200'>--></td></tr>
<tr valign='top'><td>Third Center</td><td>
<?php
$queryloc="select * from timesheet_location order by location";
$resultloc=mysqli_query($conn,$queryloc) or die(mysqli_query($conn,));
?>
<select name='thirdcenter'>
<option value="">Select Center</option>
<?php
while($num=mysqli_fetch_array($resultloc))
{
if($num[location]=="S.Extn")
{
echo"<option value='".$num[location]."' ";
if($dbObject->getDbField('thirdcenter')==$num[location])
{
echo"selected";
}
echo">South Extension</option>";
}
else
{
echo"<option value='".$num[location]."' ";
if($dbObject->getDbField('thirdcenter')==$num[location])
{
echo"selected";
}
echo">".$num[location]."</option>";
}
}
?>
</select>
<!--<input type='text' name='primarycenter' value="<?php echo $dbObject->getDbField('primarycenter');?>" size='20' maxlength='200'>--></td></tr>
<tr valign='top'><td>Date Of Joining</td><td><input type='text' name='dateofjoin' value="<?php echo $dbObject->getDbField('dateofjoin');?>" size='20' maxlength='200' id="datepicker" readonly></td></tr>
<tr valign='top'><td>Rate Group</td><td><input type="radio" name='rateGroup' value="Rate1" <?php
if($dbObject->getDbField('rateGroup')=="")
{
echo"checked";
}
else if($dbObject->getDbField('rateGroup')=="Rate1")
{
echo"checked";
}
?> >Rate1(0-499 hours) <br />
<input type="radio" name='rateGroup' value="Rate2" <?php
if($dbObject->getDbField('rateGroup')=="Rate2")
{
echo"checked";
}
?> >Rate2(500-999 hours)
<br />
<input type="radio" name='rateGroup' value="Rate3" <?php
if($dbObject->getDbField('rateGroup')=="Rate3")
{
echo"checked";
}
?> >Rate3(1000-1500 hours)
<br />
<input type="radio" name='rateGroup' value="Rate4" <?php
if($dbObject->getDbField('rateGroup')=="Rate4")
{
echo"checked";
}
?> >Rate4(1500+ hours)
<br />
<input type="radio" name='rateGroup' value="N/A" <?php
if($dbObject->getDbField('rateGroup')=="N/A")
{
echo"checked";
}
?> >N/A
</td></tr>
<tr valign='top'><td>Contract Type</td><td>
<input type="radio" name='pay_type' value="Hourly" <?php
if($dbObject->getDbField('pay_type')=="")
{
echo"checked";
}
else if($dbObject->getDbField('pay_type')=="Hourly")
{
echo"checked";
}
?> >Hourly
<input type="radio" name='pay_type' value="Fixed salaried" <?php
if($dbObject->getDbField('pay_type')=="Fixed salaried")
{
echo"checked";
}?> >Fixed salaried
</td></tr>
<?php
$languages_array=array("English"=>"English","French"=>"French","German"=>"German","Hindi"=>"Hindi","Spanish"=>"Spanish");
$languages_selected=array();
$languages_selected[]=$dbObject->getDbField('isEnglish');
$languages_selected[]=$dbObject->getDbField('isFrench');
$languages_selected[]=$dbObject->getDbField('isGerman');
$languages_selected[]=$dbObject->getDbField('isHindi');
$languages_selected[]=$dbObject->getDbField('isSpanish');
$languages_extra='style=""';
?>
<tr><td>Languages Known</td><td><?php echo check_buttons_N($languages_array,'languages_known',$languages_selected,$languages_extra,5); ?></td></tr>
<?php
$designation= new dbHandler();
$designation->connect();
$query_designation="select recNo,designation from ingl_designation order by designation";
$result_designation=$designation->select($query_designation);
$designation_array=array();
while($data_designation=$designation->SelectNext($result_designation))
{
$designation_array[''.$data_designation[recNo].'']=$data_designation['designation'];
}
$designation_selected=$dbObject->getDbField('designation');
$designation_extra='style="width:200px;" class="required"';
?>
<tr><td>Designation</td><td><?php echo select_drop($designation_array,'designation','Select Designation','',$designation_selected,$designation_extra); ?></td></tr>
<?php
$rapply= new dbHandler();
$rapply->connect();
$query_rapply="select recNo,designation from ingl_conveyance_designation order by designation";
$result_rapply=$rapply->select($query_rapply);
$rapply_array=array();
$rapply_array[0]="Not Applied";
while($data_rapply=$rapply->SelectNext($result_rapply))
{
$rapply_array[''.$data_rapply[recNo].'']=$data_rapply['designation'];
}
$rapply_selected=$dbObject->getDbField('rates_designation');
$rapply_extra='style="width:200px;" class="required"';
?>
<tr><td>Rates Apply </td><td><?php echo select_drop($rapply_array,'rates_designation','Select Rates Apply','',$rapply_selected,$rapply_extra); ?>
<input type="checkbox" name="actual_exp" value="Y" <?php if($dbObject->getDbField('actual_exp')=="Y") echo"checked"; ?>> Actual Exp.</td></tr>
<tr><td valign="top">Kms From Home </td>
<td>
<?php
$queryS1="Select * from timesheet_location where show_conveyance=1 order by order_rates";
$resultS1=mysqli_query($conn,$queryS1);
echo"<table><tr>";
while($numS1=mysqli_fetch_array($resultS1))
{
?>
<td style="background-color:#CCCCCC;"><?php echo $numS1['location']; ?></td>
<?php
}
echo"</tr>";
$queryS1="Select * from timesheet_location where show_conveyance=1 order by order_rates";
$resultS1=mysqli_query($conn,$queryS1);
echo"<tr>";
while($numS1=mysqli_fetch_array($resultS1))
{
$query_home="select * from ingl_conveyance_home_kms where center_to='".$numS1['recNo']."' && user_recNo='".$_REQUEST['kV']."'";
$result_home=mysqli_query($conn,$query_home);
$num_home=mysqli_fetch_array($result_home);
$count_home=mysqli_num_rows($result_home);
if($count_home>0)
{
$val_home=$num_home['kms'];
}
else
{
$val_home=0;
}
?>
<td><input type='hidden' name='center_to[]' value="<?php echo $numS1['recNo']; ?>" size="10 " /> <input type='text' name='kms[]' value='<?php echo $val_home; ?>' size="10 " /></td>
<?php
}
echo"</tr>";
echo"</table>";
?>
</td></tr>
<?php
$levels=array("1A"=>"1A","1B"=>"1B","1B+"=>"1B+","2A"=>"2A","2A+"=>"2A+","2B"=>"2B","3A"=>"3A","3B"=>"3B","4"=>"4","5"=>"5");
$join_teach_selected=$dbObject->getDbField('join_teach');
$join_teach_extra='style="width:200px;" class="required"';
$current_teach_selected=$dbObject->getDbField('current_teach');
$current_teach_extra='style="width:200px;" class="required"';
?>
<tr><td>On joining, eligible to teach up to</td><td><?php echo select_drop($levels,'join_teach','Select','',$join_teach_selected,$join_teach_extra); ?></td></tr>
<?php
$levels1=array("1A"=>"1A","1B"=>"1B","1B+"=>"1B+","2A"=>"2A","2A+"=>"2A+","2B"=>"2B","3A"=>"3A","3B"=>"3B","4"=>"4","5"=>"5","Module/skills"=>"Module/skills","Lesson observation"=>"Lesson observation","Private"=>"Private");
$levels_array=explode(", ", $current_teach_selected);
?>
<tr><td>Currently eligible to teach up to</td><td id="content1">
<select multiple="multiple" id="select" name="current_teach_select">
<?php
foreach($levels1 as $key=>$val)
{
echo"<option value='".$key."' ";
if(in_array($key,$levels_array))
{
echo"selected";
}
echo">".$val."</option>";
}
?>
</select>
<input type="text" id="target" name="current_teach" value="<?php echo $current_teach_selected; ?>"/>
<?php //echo select_drop($levels,'current_teach','Select','',$current_teach_selected,$current_teach_extra); ?></td></tr>
<tr><td colspan="2">
<table width="100%">
<tr><td colspan="2" bgcolor="#CCCCCC">Address</td></tr>
<tr>
<td><table><tr><td>Address1</td><td><textarea name="add1"><?php echo $dbObject->getDbField('add1'); ?></textarea></td></tr>
<tr><td>City1</td><td><input type="text" name="city1" value="<?php echo $dbObject->getDbField('city1'); ?>" /></td></tr>
<tr><td>State1</td><td><input type="text" name="state1" value="<?php echo $dbObject->getDbField('state1'); ?>" /></td></tr>
<tr><td>Pin1</td><td><input type="text" name="pin1" value="<?php echo $dbObject->getDbField('pin1'); ?>" /></td></tr>
<tr><td>Country1</td><td><input type="text" name="Country1" value="<?php echo $dbObject->getDbField('Country1'); ?>" /></td></tr></table>
</td>
<td>
<table>
<tr><td>Address2</td><td><textarea name="add2"><?php echo $dbObject->getDbField('add2'); ?></textarea></td></tr>
<tr><td>City2</td><td><input type="text" name="city2" value="<?php echo $dbObject->getDbField('city2'); ?>" /></td></tr>
<tr><td>State2</td><td><input type="text" name="state2" value="<?php echo $dbObject->getDbField('state2'); ?>" /></td></tr>
<tr><td>Pin2</td><td><input type="text" name="pin2" value="<?php echo $dbObject->getDbField('pin2'); ?>" /></td></tr>
<tr><td>Country2</td><td><input type="text" name="Country2" value="<?php echo $dbObject->getDbField('Country2'); ?>" /></td></tr>
</table>
</td>
</tr>
</table>
</td></tr>
<?php
$recruitment= new dbHandler();
$recruitment->connect();
$query_recruitment="select recNo,source_recu from ingl_recruitment_source order by source_recu";
$result_recruitment=$recruitment->select($query_recruitment);
$recruitment_array=array();
while($data_recruitment=$recruitment->SelectNext($result_recruitment))
{
$recruitment_array[''.$data_recruitment[recNo].'']=$data_recruitment['source_recu'];
}
$recruitment_selected=$dbObject->getDbField('recruitment_source');
$recruitment_extra='style="width:200px;" class="required"';
?>
<tr valign='top'><td>Recruitment Source</td><td><?php echo select_drop($recruitment_array,'recruitment_source','Select Source','',$recruitment_selected,$recruitment_extra); ?></td></tr>
<?php
if($currentMode=="Add")
{
?>
<tr valign='top'><td>Documents received at time of joining</td><td><div id="myDiv" style="width:100%">
<div style="width:100%;float:left;border:0px solid #cccccc;">
<div style="float:left;width:100%"> <input type="text" style="width:120px;" name="document_submitted[]" /></div>
</div>
</div>
<?php
}
else
{
$documents_rcvd= new dbHandler();
$documents_rcvd->connect();
$query_documents_rcvd="select recNo,document_submitted from ingl_user_document_receive where user_recNo='".$dbObject->getDbField('recNo')."'";
$result_documents_rcvd=$documents_rcvd->select($query_documents_rcvd);
$tot=1;
while($data_documents_rcvd=$documents_rcvd->SelectNext($result_documents_rcvd))
{
$files_show.='<div style="width:100%;float:left;border:0px solid #cccccc;" id="my'.$tot.'myDiv" >
<div style="float:left;width:100%" > <input type="text" style="width:120px;" name="document_submitted[]" value="'.$data_documents_rcvd['document_submitted'].'" /><a href="javascript: if(confirm(\'Are You Sure?\')) { removeElement(\'myDiv\',\'my'.$tot.'myDiv\'); }"><img src="images/delete.png" style="border:none;" width="10" height="10" /></a></div></div>';
$tot++;
}
?>
<tr valign='top'><td>Documents received at time of joining</td><td>
<?php
echo'<div id="myDiv" style="width:100%">';
echo $files_show;
echo"</div><br>";
}
?>
<?php
if($currentMode=="Add")
{
$tot=2;
}
else
{
$tot=$tot;
}
?>
<input type="hidden" value="<?php echo $tot; ?>" id="theValue" />
<table width="100%"><tr><td><span style="text-align:left;border:#00FFCC solid 0px;width:100%" id="sub"><a href='javascript:displayStu("sub","1","document.php","myDiv","theValue")'><b>Add Another Record</b></a></span></td></tr></table>
</td></tr>
<?php
if($currentMode=="Add")
{
?>
<tr valign='top'><td>Education</td><td>
<div id="myDiv1" style="width:100%">
<div style="width:100%;float:left;border:0px solid #cccccc;">
<div style="float:left;width:100%"> <input type="text" style="width:140px;" name="education[]" /></div>
</div>
</div>
<?php
}
else
{
$documents_rcvd= new dbHandler();
$documents_rcvd->connect();
$query_documents_rcvd="select recNo,education from ingl_user_education where user_recNo='".$dbObject->getDbField('recNo')."'";
$result_documents_rcvd=$documents_rcvd->select($query_documents_rcvd);
$tot1=1;
while($data_documents_rcvd=$documents_rcvd->SelectNext($result_documents_rcvd))
{
$files_show1.='<div style="width:100%;float:left;border:0px solid #cccccc;" id="my'.$tot1.'myDiv1">
<div style="float:left;width:100%"> <input type="text" style="width:140px;" name="education[]" value="'.$data_documents_rcvd['education'].'" /><a href="javascript: if(confirm(\'Are You Sure?\')) { removeElement(\'myDiv1\',\'my'.$tot1.'myDiv1\'); }"><img src="images/delete.png" style="border:none;" width="10" height="10" /></a></div>
</div>';
$tot1++;
}
?>
<tr valign='top'><td>Education</td><td>
<?php
echo'<div id="myDiv1" style="width:100%">';
echo $files_show1;
echo"</div><br>";
}
?>
<?php
if($currentMode=="Add")
{
$tot1=2;
}
else
{
$tot1=$tot1;
}
?>
<input type="hidden" value="<?php echo $tot1; ?>" id="theValue1" />
<table width="100%"><tr><td><span style="text-align:left;border:#00FFCC solid 0px;width:100%" id="sub1"><a href='javascript:displayStu("sub1","1","education.php","myDiv1","theValue1")'><b>Add Another Record</b></a></span></td></tr></table>
</td></tr>
<?php
if($currentMode=="Add")
{
?>
<tr valign='top'><td>Additional qualification</td><td>
<div id="myDiv2" style="width:100%">
<div style="width::100%;float:left;border:0px solid #cccccc;">
<div style="float:left;width:100%"> <input type="text" style="width:140px;" name="add_qualification[]" /></div>
</div>
</div>
<?php
}
else
{
$documents_rcvd= new dbHandler();
$documents_rcvd->connect();
$query_documents_rcvd="select recNo,add_qualification from ingl_user_add_qualification where user_recNo='".$dbObject->getDbField('recNo')."'";
$result_documents_rcvd=$documents_rcvd->select($query_documents_rcvd);
$tot2=1;
while($data_documents_rcvd=$documents_rcvd->SelectNext($result_documents_rcvd))
{
$files_show2.='<div style="width:100%;float:left;border:0px solid #cccccc;" id="my'.$tot2.'myDiv2">
<div style="float:left;width:100%"> <input type="text" style="width:140px;" name="add_qualification[]" value="'.$data_documents_rcvd['add_qualification'].'" /><a href="javascript: if(confirm(\'Are You Sure?\')) { removeElement(\'myDiv2\',\'my'.$tot2.'myDiv2\'); }"><img src="images/delete.png" style="border:none;" width="10" height="10" /></a></div>
</div>';
$tot2++;
}
?>
<tr valign='top'><td>Additional qualification</td><td>
<?php
echo'<div id="myDiv2" style="width:100%">';
echo $files_show2;
echo"</div><br>";
}
?>
<?php
if($currentMode=="Add")
{
$tot2=2;
}
else
{
$tot2=$tot2;
}
?>
<input type="hidden" value="<?php echo $tot2; ?>" id="theValue2" />
<table width="100%"><tr><td><span style="text-align:left;border:#00FFCC solid 0px;width:100%" id="sub2"><a href='javascript:displayStu("sub2","1","add_qualification.php","myDiv2","theValue2")'><b>Add Another Record</b></a></span></td></tr></table>
</td></tr>
<?php
if($currentMode=="Add")
{
?>
<tr valign='top'><td>Contract Details</td><td>
<div id="myDiv3" style="width:100%">
<div style="width:100%;float:left;border:0px solid #cccccc;">
<div style="float:left;width:39%;background:#CCCCCC;"> Details</div>
<div style="float:left;width:30%;background:#CCCCCC;"> From</div>
<div style="float:left;width:30%;background:#CCCCCC;"> To</div>
</div>
<div style="width:100%;float:left;border:0px solid #cccccc;">
<div style="float:left;width:39%"> <input type="text" style="width:120px;" name="contract_details[]" onclick="dd('contact_from1');dd('contact_to1');" /></div>
<div style="float:left;width:30%"> <input type="text" style="width:100px;" name="contract_from[]" id="contact_from1" onclick="dd(this.id);"/></div>
<div style="float:left;width:30%"> <input type="text" style="width:100px;" name="contract_to[]" id="contact_to1" onclick="dd(this.id);"/></div>
</div>
</div>
<?php
}
else
{
$files_show3='<div style="width:100%;float:left;border:0px solid #cccccc;">
<div style="float:left;width:39%;background:#CCCCCC;"> Details</div>
<div style="float:left;width:30%;background:#CCCCCC;"> From</div>
<div style="float:left;width:30%;background:#CCCCCC;"> To</div>
</div>';
$documents_rcvd= new dbHandler();
$documents_rcvd->connect();
$query_documents_rcvd="select * from ingl_user_contract_details where user_recNo='".$dbObject->getDbField('recNo')."'";
$result_documents_rcvd=$documents_rcvd->select($query_documents_rcvd);
$tot3=1;
while($data_documents_rcvd=$documents_rcvd->SelectNext($result_documents_rcvd))
{
$files_show3.='<div style="width:100%;float:left;border:0px solid #cccccc;" id="my'.$tot3.'myDiv3">
<div style="float:left;width:39%"> <input type="text" style="width:120px;" name="contract_details[]" value="'.$data_documents_rcvd['contract_details'].'" onclick="dd(\'contact_from'.$tot3.'\');dd(\'contact_to'.$tot3.'\');" /></div>
<div style="float:left;width:30%"> <input type="text" style="width:100px;" name="contract_from[]" value="'.$data_documents_rcvd['contract_from'].'" id="contact_from'.$tot3.'" onclick="dd(this.id);" /></div>
<div style="float:left;width:30%"> <input type="text" style="width:90px;" name="contract_to[]" value="'.$data_documents_rcvd['contract_to'].'" onclick="dd(this.id);" id="contact_to'.$tot3.'" /><a href="javascript: if(confirm(\'Are You Sure?\')) { removeElement(\'myDiv3\',\'my'.$tot3.'myDiv3\'); }"><img src="images/delete.png" style="border:none;" width="10" height="10" /></a></div>
</div>';
$tot3++;
}
?>
<tr valign='top'><td>Contract Details</td><td>
<?php
echo'<div id="myDiv3" style="width:100%">';
echo $files_show3;
echo"</div><br>";
}
?>
<?php
if($currentMode=="Add")
{
$tot3=2;
}
else
{
$tot3=$tot3;
}
?>
<input type="hidden" value="<?php echo $tot3; ?>" id="theValue3" />
<table width="100%"><tr><td><span style="text-align:left;border:#00FFCC solid 0px;width:100%" id="sub3"><a href='javascript:displayStu("sub3","1","contract_details.php","myDiv3","theValue3")'><b>Add Another Record</b></a></span></td></tr></table>
</td></tr>
<?php
if($currentMode=="Add")
{
?>
<tr valign='top'><td>Designation</td><td>
<?php
$designation_extra1="onclick='dd(\"designation_date1\")'";
?>
<div id="myDiv4" style="width:100%">
<div style="width:100%;float:left;border:0px solid #cccccc;">
<div style="float:left;width:60%;background:#CCCCCC;"> Designation</div>
<div style="float:left;width:39%;background:#CCCCCC;"> From Date</div>
</div>
<div style="width:100%;float:left;border:0px solid #cccccc;">
<div style="float:left;width:60%"> <?php echo select_drop($designation_array,'designation1[]','Select Designation','',$designation_selected,$designation_extra1); ?></div>
<div style="float:left;width:39%"> <input type="text" style="width:100px;" name="designation_date[]" id="designation_date1" onclick="dd(this.id);"/></div>
</div>
</div>
<?php
}
else
{
$files_show4='<div style="width:100%;float:left;border:0px solid #cccccc;">
<div style="float:left;width:60%;background:#CCCCCC;"> Designation</div>
<div style="float:left;width:39%;background:#CCCCCC;"> From Date</div>
</div>';
$documents_rcvd= new dbHandler();
$documents_rcvd->connect();
$query_documents_rcvd="select a.*,b.designation from ingl_user_designation a left join ingl_designation b on a.designation_1=b.recNo where a.user_recNo='".$dbObject->getDbField('recNo')."'";
$result_documents_rcvd=$documents_rcvd->select($query_documents_rcvd);
$tot4=1;
while($data_documents_rcvd=$documents_rcvd->SelectNext($result_documents_rcvd))
{
$files_show4.='<div style="width:100%;float:left;border:0px solid #cccccc;" id="my'.$tot4.'myDiv4">
<div style="float:left;width:60%"> '.select_drop($designation_array,'designation1[]','Select Designation','',$data_documents_rcvd['designation_1'],$designation_extra).'</div>
<div style="float:left;width:39%"> <input type="text" style="width:100px;" name="designation_date[]" value="'.$data_documents_rcvd['designation_date'].'" id="designation_date'.$tot4.'" onclick="dd(this.id);" /><a href="javascript: if(confirm(\'Are You Sure?\')) { removeElement(\'myDiv4\',\'my'.$tot4.'myDiv4\'); }"><img src="images/delete.png" style="border:none;" width="10" height="10" /></a></div>
</div>';
$tot4++;
}
?>
<tr valign='top'><td>Designation</td><td>
<?php
echo'<div id="myDiv4" style="width:100%">';
echo $files_show4;
echo"</div><br>";
}
?>
<?php
if($currentMode=="Add")
{
$tot4=2;
}
else
{
$tot4=$tot4;
}
?>
<input type="hidden" value="<?php echo $tot4; ?>" id="theValue4" />
<table width="100%"><tr><td><span style="text-align:left;border:#00FFCC solid 0px;width:100%" id="sub4"><a href='javascript:displayStu("sub4","1","designation_details.php","myDiv4","theValue4")'><b>Add Another Record</b></a></span></td></tr></table>
</td></tr>
<?php
$training= new dbHandler();
$training->connect();
$query_training="select recNo,nameofWorkshop from ingl_workshops order by nameofWorkshop";
$result_training=$training->select($query_training);
$training_array=array();
while($data_training=$training->SelectNext($result_training))
{
$training_array[''.$data_training[recNo].'']=$data_training['nameofWorkshop'];
}
$training_selected=$dbObject->getDbField('training');
$training_extra='style="width:140px;" onclick="dd(\'training_from1\');dd(\'training_to1\');"';
if($currentMode=="Add")
{
?>
<tr valign='top'><td>Internal training details </td><td>
<div id="myDiv5" style="width:100%">
<div style="width:100%;float:left;border:0px solid #cccccc;">
<div style="float:left;width:39%;background:#CCCCCC;"> Details</div>
<div style="float:left;width:30%;background:#CCCCCC;"> From</div>
<div style="float:left;width:30%;background:#CCCCCC;"> To</div>
</div>
<div style="width:100%;float:left;border:0px solid #cccccc;">
<div style="float:left;width:39%"> <?php echo select_drop($training_array,'training[]','Select Training','',$training_selected,$training_extra); ?></div>
<div style="float:left;width:30%"> <input type="text" style="width:100px;" name="training_from[]" id="training_from1" onclick="dd(this.id);" /></div>
<div style="float:left;width:30%"> <input type="text" style="width:100px;" name="training_to[]" id="training_to1" onclick="dd(this.id);" /></div>
</div>
</div>
<?php
}
else
{
$files_show5='<div style="width:100%;float:left;border:0px solid #cccccc;">
<div style="float:left;width:39%;background:#CCCCCC;"> Details</div>
<div style="float:left;width:30%;background:#CCCCCC;"> From</div>
<div style="float:left;width:30%;background:#CCCCCC;"> To</div>
</div>';
$documents_rcvd= new dbHandler();
$documents_rcvd->connect();
$query_documents_rcvd="select a.*,b.nameofWorkshop from ingl_user_internal_training a left join ingl_workshops b on a.training=b.recNo where a.user_recNo='".$dbObject->getDbField('recNo')."'";
$result_documents_rcvd=$documents_rcvd->select($query_documents_rcvd);
$tot5=1;
while($data_documents_rcvd=$documents_rcvd->SelectNext($result_documents_rcvd))
{
$files_show5.='<div style="width:100%;float:left;border:0px solid #cccccc;" id="my'.$tot5.'myDiv5">
<div style="float:left;width:39%"> '.select_drop($training_array,'training[]','Select Training','',$data_documents_rcvd['training'],$training_extra).'</div>
<div style="float:left;width:30%"> <input type="text" style="width:100px;" name="training_from[]" value="'.$data_documents_rcvd['training_from'].'" id="training_from'.$tot5.'" onclick="dd(this.id);" /></div>
<div style="float:left;width:30%"> <input type="text" style="width:90px;" name="training_to[]" value="'.$data_documents_rcvd['training_to'].'" id="training_to'.$tot5.'" onclick="dd(this.id);" /><a href="javascript: if(confirm(\'Are You Sure?\')) { removeElement(\'myDiv5\',\'my'.$tot5.'myDiv5\'); }"><img src="images/delete.png" style="border:none;" width="10" height="10" /></a></div>
</div>';
$tot5++;
}
?>
<tr valign='top'><td>Internal training details</td><td>
<?php
echo'<div id="myDiv5" style="width:100%">';
echo $files_show5;
echo"</div><br>";
}
?>
<?php
if($currentMode=="Add")
{
$tot5=2;
}
else
{
$tot5=$tot5;
}
?>
<input type="hidden" value="<?php echo $tot5; ?>" id="theValue5" />
<table width="100%"><tr><td><span style="text-align:left;border:#00FFCC solid 0px;width:100%" id="sub5"><a href='javascript:displayStu("sub5","1","internal_training_details.php","myDiv5","theValue5")'><b>Add Another Record</b></a></span></td></tr></table>
</td></tr>
<?php
if($currentMode=="Add")
{
?>
<tr valign='top'><td>External training details </td><td>
<div id="myDiv6" style="width:100%">
<div style="width:100%;float:left;border:0px solid #cccccc;">
<div style="float:left;width:39%;background:#CCCCCC;"> Details</div>
<div style="float:left;width:30%;background:#CCCCCC;"> From</div>
<div style="float:left;width:30%;background:#CCCCCC;"> To</div>
</div>
<div style="width:100%;float:left;border:0px solid #cccccc;">
<div style="float:left;width:39%"> <input type="text" style="width:120px;" name="external_training[]" onclick="dd('external_training_from1');dd('external_training_to1')"; /></div>
<div style="float:left;width:30%"> <input type="text" style="width:100px;" name="external_training_from[]" id="external_training_from1" onclick="dd(this.id);" /></div>
<div style="float:left;width:30%"> <input type="text" style="width:100px;" name="external_training_to[]" id="external_training_to1" onclick="dd(this.id);"/></div>
</div>
</div>
<?php
}
else
{
$files_show6='<div style="width:100%;float:left;border:0px solid #cccccc;">
<div style="float:left;width:39%;background:#CCCCCC;"> Details</div>
<div style="float:left;width:30%;background:#CCCCCC;"> From</div>
<div style="float:left;width:30%;background:#CCCCCC;"> To</div>
</div>';
$documents_rcvd= new dbHandler();
$documents_rcvd->connect();
$query_documents_rcvd="select * from ingl_user_external_training where user_recNo='".$dbObject->getDbField('recNo')."'";
$result_documents_rcvd=$documents_rcvd->select($query_documents_rcvd);
$tot6=1;
while($data_documents_rcvd=$documents_rcvd->SelectNext($result_documents_rcvd))
{
$files_show6.='<div style="width:100%;float:left;border:0px solid #cccccc;" id="my'.$tot6.'myDiv6">
<div style="float:left;width:39%"> <input type="text" style="width:120px;" name="external_training[]" value="'.$data_documents_rcvd['external_training'].'" onclick="dd(\'external_training_from'.$tot6.'\');dd(\'external_training_to'.$tot6.'\')"; /></div>
<div style="float:left;width:30%"> <input type="text" style="width:100px;" name="external_training_from[]" value="'.$data_documents_rcvd['external_training_from'].'" id="external_training_from'.$tot6.'" onclick="dd(this.id);" /></div>
<div style="float:left;width:30%"> <input type="text" style="width:90px;" name="external_training_to[]" value="'.$data_documents_rcvd['external_training_to'].'" id="external_training_to'.$tot6.'" onclick="dd(this.id);" /><a href="javascript: if(confirm(\'Are You Sure?\')) { removeElement(\'myDiv6\',\'my'.$tot6.'myDiv6\'); }"><img src="images/delete.png" style="border:none;" width="10" height="10" /></a></div>
</div>';
$tot6++;
}
?>
<tr valign='top'><td>External training details</td><td>
<?php
echo'<div id="myDiv6" style="width:100%">';
echo $files_show6;
echo"</div><br>";
}
?>
<?php
if($currentMode=="Add")
{
$tot6=2;
}
else
{
$tot6=$tot6;
}
?>
<input type="hidden" value="<?php echo $tot6; ?>" id="theValue6" />
<table width="100%"><tr><td><span style="text-align:left;border:#00FFCC solid 0px;width:100%" id="sub6"><a href='javascript:displayStu("sub6","1","external_training_details.php","myDiv6","theValue6")'><b>Add Another Record</b></a></span></td></tr></table>
</td></tr>
<?php
if($currentMode=="Add")
{
?>
<tr valign='top'><td>Disciplinary action taken </td><td>
<div id="myDiv7" style="width:100%">
<div style="width:100%;float:left;border:0px solid #cccccc;">
<div style="float:left;width:60%;background:#CCCCCC;"> Action</div>
<div style="float:left;width:39%;background:#CCCCCC;"> From Date</div>
</div>
<div style="width:100%;float:left;border:0px solid #cccccc;">
<div style="float:left;width:60%"> <input type="text" name="discline_action[]" onclick="dd('discline_action_date1');" /></div>
<div style="float:left;width:39%"> <input type="text" style="width:100px;" name="discline_action_date[]" id="discline_action_date1" onclick="dd(this.id);" /></div>
</div>
</div>
<?php
}
else
{
$files_show7='<div style="width:100%;float:left;border:0px solid #cccccc;">
<div style="float:left;width:60%;background:#CCCCCC;"> Action</div>
<div style="float:left;width:39%;background:#CCCCCC;"> From Date</div>
</div>';
$documents_rcvd= new dbHandler();
$documents_rcvd->connect();
$query_documents_rcvd="select * from ingl_user_discpline_action where user_recNo='".$dbObject->getDbField('recNo')."'";
$result_documents_rcvd=$documents_rcvd->select($query_documents_rcvd);
$tot7=1;
while($data_documents_rcvd=$documents_rcvd->SelectNext($result_documents_rcvd))
{
$files_show7.='<div style="width:100%;float:left;border:0px solid #cccccc;" id="my'.$tot7.'myDiv7">
<div style="float:left;width:60%"> <input type="text" name="discline_action[]" value="'.$data_documents_rcvd['discline_action'].'" onclick="dd(\'discline_action_date'.$tot7.'\');" /></div>
<div style="float:left;width:39%"> <input type="text" style="width:100px;" name="discline_action_date[]" value="'.$data_documents_rcvd['discline_action_date'].'" id="discline_action_date'.$tot7.'" onclick="dd(this.id);"/><a href="javascript: if(confirm(\'Are You Sure?\')) { removeElement(\'myDiv7\',\'my'.$tot7.'myDiv7\'); }"><img src="images/delete.png" style="border:none;" width="10" height="10" /></a></div>
</div>';
$tot7++;
}
?>
<tr valign='top'><td>Disciplinary action taken </td><td>
<?php
echo'<div id="myDiv7" style="width:100%">';
echo $files_show7;
echo"</div><br>";
}
?>
<?php
if($currentMode=="Add")
{
$tot7=2;
}
else
{
$tot7=$tot7;
}
?>
<input type="hidden" value="<?php echo $tot7; ?>" id="theValue7" />
<table width="100%"><tr><td><span style="text-align:left;border:#00FFCC solid 0px;width:100%" id="sub7"><a href='javascript:displayStu("sub7","1","discpline_details.php","myDiv7","theValue7")'><b>Add Another Record</b></a></span></td></tr></table>
</td></tr>
<?php
if($currentMode=="Add")
{
?>
<tr valign='top'><td>Eligible to conduct internal trainings?</td><td>
<div id="myDiv8" style="width:100%">
<div style="width:100%;float:left;border:0px solid #cccccc;">
<div style="float:left;width:100%"> <?php echo select_drop($training_array,'eligible_training[]','Select Training','',$training_selected,$training_extra); ?></div>
</div>
</div>
<?php
}
else
{
$documents_rcvd= new dbHandler();
$documents_rcvd->connect();
$query_documents_rcvd="select a.*,b.nameofWorkshop from ingl_user_training_eligible a left join ingl_workshops b on a.eligible_training=b.recNo where a.user_recNo='".$dbObject->getDbField('recNo')."'";
$result_documents_rcvd=$documents_rcvd->select($query_documents_rcvd);
$tot8=1;
while($data_documents_rcvd=$documents_rcvd->SelectNext($result_documents_rcvd))
{
$files_show8.='<div style="width:100%;float:left;border:0px solid #cccccc;" id="my'.$tot8.'myDiv8">
<div style="float:left;width:100%"> '.select_drop($training_array,'eligible_training[]','Select Training','',$data_documents_rcvd['eligible_training'],$training_extra).'<a href="javascript: if(confirm(\'Are You Sure?\')) { removeElement(\'myDiv8\',\'my'.$tot8.'myDiv8\'); }"><img src="images/delete.png" style="border:none;" width="10" height="10" /></a></div>
</div>';
$tot8++;
}
?>
<tr valign='top'><td>Eligible to conduct internal trainings?</td><td>
<?php
echo'<div id="myDiv8" style="width:100%">';
echo $files_show8;
echo"</div><br>";
}
?>
<?php
if($currentMode=="Add")
{
$tot8=2;
}
else
{
$tot8=$tot8;
}
?>
<input type="hidden" value="<?php echo $tot8; ?>" id="theValue8" />
<table width="100%"><tr><td><span style="text-align:left;border:#00FFCC solid 0px;width:100%" id="sub8"><a href='javascript:displayStu("sub8","1","internal_training_eligibility.php","myDiv8","theValue8")'><b>Add Another Record</b></a></span></td></tr></table>
</td></tr>
<?php
if($currentMode=="Add")
{
?>
<tr valign='top'><td>Grievance process</td><td>
<div id="myDiv9" style="width:100%">
<div style="width:100%;float:left;border:0px solid #cccccc;">
<div style="float:left;width:60%;background:#CCCCCC;"> Prcocess</div>
<div style="float:left;width:39%;background:#CCCCCC;"> From Date</div>
</div>
<div style="width:100%;float:left;border:0px solid #cccccc;">
<div style="float:left;width:60%"> <input type="text" name="grievance[]" onclick="dd('grievance_date1');"/></div>
<div style="float:left;width:39%"> <input type="text" style="width:100px;" name="grievance_date[]" id="grievance_date1" onclick="dd(this.id);" /></div>
</div>
</div>
<?php
}
else
{
$files_show9='
<div style="width:100%;float:left;border:0px solid #cccccc;" >
<div style="float:left;width:60%;background:#CCCCCC;"> Prcocess</div>
<div style="float:left;width:39%;background:#CCCCCC;"> From Date</div>
</div>';
$documents_rcvd= new dbHandler();
$documents_rcvd->connect();
$query_documents_rcvd="select * from ingl_user_grievance where user_recNo='".$dbObject->getDbField('recNo')."'";
$result_documents_rcvd=$documents_rcvd->select($query_documents_rcvd);
$tot9=1;
while($data_documents_rcvd=$documents_rcvd->SelectNext($result_documents_rcvd))
{
$files_show9.='<div style="width:100%;float:left;border:0px solid #cccccc;" id="my'.$tot9.'myDiv9">
<div style="float:left;width:60%"> <input type="text" name="grievance[]" value="'.$data_documents_rcvd['grievance'].'" onclick="dd(\'grievance_date'.$tot9.'\');" /></div>
<div style="float:left;width:39%"> <input type="text" style="width:100px;" name="grievance_date[]" value="'.$data_documents_rcvd['grievance_date'].'" id="grievance_date'.$tot9.'" onclick="dd(this.id);" /><a href="javascript: if(confirm(\'Are You Sure?\')) { removeElement(\'myDiv9\',\'my'.$tot9.'myDiv9\'); }"><img src="images/delete.png" style="border:none;" width="10" height="10" /></a></div>
</div>';
$tot9++;
}
?>
<tr valign='top'><td>Grievance process</td><td>
<?php
echo'<div id="myDiv9" style="width:100%">';
echo $files_show9;
echo"</div><br>";
}
?>
<?php
if($currentMode=="Add")
{
$tot9=2;
}
else
{
$tot9=$tot9;
}
?>
<input type="hidden" value="<?php echo $tot9; ?>" id="theValue9" />
<table width="100%"><tr><td><span style="text-align:left;border:#00FFCC solid 0px;width:100%" id="sub9"><a href='javascript:displayStu("sub9","1","gre_details.php","myDiv9","theValue9")'><b>Add Another Record</b></a></span></td></tr></table>
</td></tr>
<!--<tr valign='top'><td>Leave Left in Year 2010-2011</td><td>
<input type='text' name='leavedaysin20102011' value="<?php echo $dbObject->getDbField('leavedaysin20102011');?>" size='10' maxlength='200' onkeypress="return isNumberKey1(event)">
</td></tr>
<tr valign='top'><td>Leave Left in Year 2011-2012</td><td>
<input type='text' name='leavedaysin20112012' value="<?php echo $dbObject->getDbField('leavedaysin20112012');?>" size='10' maxlength='200' onkeypress="return isNumberKey1(event)">
</td></tr>-->
<!--<tr valign='top'><td>Leave Alloted in Year 2012-2013</td><td>
<input type='text' name='leavedaysin20122013' value="<?php echo $dbObject->getDbField('leavedaysin20122013');?>" size='10' maxlength='200' onkeypress="return isNumberKey1(event)" readonly>
</td></tr>
<tr valign='top'><td>Leave Alloted in Year 2013-2014</td><td>
<input type='text' name='leavedaysin20132014' value="<?php echo $dbObject->getDbField('leavedaysin20132014');?>" size='10' maxlength='200' onkeypress="return isNumberKey1(event)" readonly>
</td></tr>-->
<tr valign='top'><td>Leave Alloted in Year 2014-2015</td><td>
<input type='text' name='leavedaysin20142015' value="<?php echo $dbObject->getDbField('leavedaysin20142015');?>" size='10' maxlength='200' onkeypress="return isNumberKey1(event)">
</td></tr>
<tr valign='top'><td>Leave Alloted in Year 2015-2016</td><td>
<input type='text' name='leavedaysin20152016' value="<?php echo $dbObject->getDbField('leavedaysin20152016');?>" size='10' maxlength='200' onkeypress="return isNumberKey1(event)">
</td></tr>
<tr valign='top'><td>Leave Alloted in Year 2016-2017</td><td>
<input type='text' name='leavedaysin20162017' value="<?php echo $dbObject->getDbField('leavedaysin20162017');?>" size='10' maxlength='200' onkeypress="return isNumberKey1(event)">
</td></tr>
<tr valign='top'><td>Leave Alloted in Year 2017-2018</td><td>
<input type='text' name='leavedaysin20172018' value="<?php echo $dbObject->getDbField('leavedaysin20172018');?>" size='10' maxlength='200' onkeypress="return isNumberKey1(event)">
<label>Superwiser</label>
<?php
$query="SELECT recNo,name FROM timesheet_user where status='Active' union all select 0 as recNo,\"--Select--\" as name order by name ";
$res=mysqli_query($conn,$query);
echo "<select name='superwiser' ";
echo"<option value='' selected='selected' >Superwiser Rights</option>";
$manager=array();
while($rsult=mysqli_fetch_array($res))
{
$manager[]=array('id'=>$rsult['recNo'],'description'=>$rsult['name']);
echo"<option value='".$rsult['recNo']."'" ;
if($dbObject->getDbField('superwiser')==$rsult['recNo'])
{
echo "selected";
}
echo">".$rsult['name']."</option>";
}
echo"</select>";
echo " Manager ";
echo "<select name='manager' ";
echo"<option value='' selected='selected'>Manager Rights</option>";
for($i=0; $i<count($manager) ;$i++)
{
echo"<option value='".$manager[$i]['id']."'" ;
if($dbObject->getDbField('manager')==$manager[$i]['id'])
{
echo "selected";
}
echo">".$manager[$i]['description']."</option>";
}
echo"</select>";
?>
</td></tr>
<?php
$array_mon=array();
$array_tue=array();
$array_wed=array();
$array_thu=array();
$array_fri=array();
$array_sat=array();
$array_sun=array();
$queryT="select * from ingl_user_timing where user_recNo='".$dbObject->getDbField('recNo')."'";
$resultT=mysqli_query($conn,$queryT);
$numT=mysqli_fetch_array($resultT);
$array_mon=explode(",",$numT['timings1']);
$array_tue=explode(",",$numT['timings2']);
$array_wed=explode(",",$numT['timings3']);
$array_thu=explode(",",$numT['timings4']);
$array_fri=explode(",",$numT['timings5']);
$array_sat=explode(",",$numT['timings6']);
$array_sun=explode(",",$numT['timings7']);
?>
<tr valign='top'><td valign="top">Timings</td>
<td>
<table width="100%">
<tr>
<td><input type="checkbox" name="mon1" id="mon1" value="Y" <?php if($numT['mon1']=="Y") echo"checked"; ?> /> Mon</td>
<td id="content1">
<select id="target_mon1" multiple="multiple">
<?php
echo timings(7,21,$array_mon);
?>
</select>
<input type="text" id="target_mon" name="timings1" value="<?php echo $timings1; ?>"/>
</td>
</tr>
<tr>
<td><input type="checkbox" name="tue1" value="Y" <?php if($numT['tue1']=="Y") echo"checked"; ?> /> Tue</td>
<td id="content1"><select id="target_tue1" multiple="multiple" >
<?php
echo timings(7,21,$array_tue);
?>
</select>
<input type="text" id="target_tue" name="timings2" value="<?php echo $timings2; ?>"/>
</td>
</tr>
<tr>
<td><input type="checkbox" name="wed1" value="Y" <?php if($numT['wed1']=="Y") echo"checked"; ?> /> Wed</td>
<td id="content1">
<select id="target_wed1" multiple="multiple" >
<?php
echo timings(7,21,$array_wed);
?>
</select>
<input type="text" id="target_wed" name="timings3" value="<?php echo $timings3; ?>"/>
</td>
</tr>
<tr>
<td><input type="checkbox" name="thu1" value="Y" <?php if($numT['thu1']=="Y") echo"checked"; ?> /> Thu</td>
<td id="content1">
<select id="target_thu1" multiple="multiple" >
<?php
echo timings(7,21,$array_thu);
?>
</select>
<input type="text" id="target_thu" name="timings4" value="<?php echo $timings4; ?>"/>
</td>
</tr>
<tr>
<td><input type="checkbox" name="fri1" value="Y" <?php if($numT['fri1']=="Y") echo"checked"; ?> /> Fri</td>
<td id="content1">
<select id="target_fri1" multiple="multiple" >
<?php
echo timings(7,21,$array_fri);
?>
</select>
<input type="text" id="target_fri" name="timings5" value="<?php echo $timings5; ?>"/>
</td>
</tr>
<tr>
<td><input type="checkbox" name="sat1" value="Y" <?php if($numT['sat1']=="Y") echo"checked"; ?>/> Sat</td>
<td id="content1">
<select id="target_sat1" multiple="multiple" >
<?php
echo timings(7,21,$array_sat);
?>
</select>
<input type="text" id="target_sat" name="timings6" value="<?php echo $timings6; ?>"/>
</td>
</tr>
<tr>
<td><input type="checkbox" name="sun1" value="Y" <?php if($numT['sun1']=="Y") echo"checked"; ?> /> Sun</td>
<td id="content1">
<select id="target_sun1" multiple="multiple">
<?php
echo timings(7,21,$array_sun);
?>
</select>
<input type="text" id="target_sun" name="timings7" value="<?php echo $timings7; ?>"/>
</td>
</tr>
</table>
</td>
</tr>
<tr valign='top'><td>Active</td><td>
<input type="radio" name='status' value="Active" <?php
if($dbObject->getDbField('status')=="")
{
echo"checked";
}
else if($dbObject->getDbField('status')=="Active")
{
echo"checked";
}
?> >Active
<input type="radio" name='status' value="Deactive" <?php
if($dbObject->getDbField('status')=="Deactive")
{
echo"checked";
}?> >Deactivated
</td></tr>
<tr><td valign="top"><b>Allowed Modules</b></td><td>
<table style="border: 1px solid #cccccc; ">
<tr>
<td valign="top" width="10" style="border-bottom: 1px solid #cccccc; "><input type="checkbox" name="indeed" value='Y' <?php if($dbObject->getDbField('indeed')=="Y") { echo"checked"; } ?> /></td><td valign="top" style="border-bottom: 1px solid #cccccc;">iNDEED</td>
<td valign="top" width="10" style="border-bottom: 1px solid #cccccc;"><input type="checkbox" name="timesheet_admin" value='Y' <?php if($dbObject->getDbField('timesheet_admin')=="Y") { echo"checked"; } ?> /></td><td valign="top" style="border-bottom: 1px solid #cccccc;">Timesheet admin</td>
<td valign="top" width="10" style="border-bottom: 1px solid #cccccc;"><input type="checkbox" name="timesheet" value='Y' <?php if($dbObject->getDbField('timesheet')=="Y") { echo"checked"; } ?> /></td><td valign="top" style="border-bottom: 1px solid #cccccc;">Timesheet</td>
<td valign="top" width="10"><input type="checkbox" name="admin_general_leave" value='Y' <?php if($dbObject->getDbField('admin_general_leave')=="Y") { echo"checked"; } ?> /></td>
<td valign="top" style="border-bottom: 1px solid #cccccc;">Admin-General-leave</td>
</tr>
<tr>
<td valign="top" width="10" style="border-bottom: 1px solid #cccccc; "><input type="checkbox" name="eoc_admin" value='Y' <?php if($dbObject->getDbField('eoc_admin')=="Y") { echo"checked"; } ?> /></td><td valign="top" style="border-bottom: 1px solid #cccccc; ">EOC Admin</td>
<td valign="top" width="10" style="border-bottom: 1px solid #cccccc; "><input type="checkbox" name="eoc" value='Y' <?php if($dbObject->getDbField('eoc')=="Y") { echo"checked"; } ?> /></td><td valign="top" style="border-bottom: 1px solid #cccccc; ">EOC</td>
<td valign="top" width="10" style="border-bottom: 1px solid #cccccc; "><input type="checkbox" name="fd" value='Y' <?php if($dbObject->getDbField('fd')=="Y") { echo"checked"; } ?> /></td><td valign="top" style="border-bottom: 1px solid #cccccc; ">CS</td>
<td valign="top" width="10"><input type="checkbox" name="admin_Rate_Master" value='Y' <?php if($dbObject->getDbField('admin_Rate_Master')=="Y") { echo"checked"; } ?> /></td>
<td valign="top" style="border-bottom: 1px solid #cccccc;">Admin-Rate-Master</td>
</tr>
<tr>
<td valign="top" width="10" style="border-bottom: 1px solid #cccccc; "><input type="checkbox" name="leavetrackeradmin" value='Y' <?php if($dbObject->getDbField('leavetrackeradmin')=="Y") { echo"checked"; } ?> /></td><td valign="top" style="border-bottom: 1px solid #cccccc; ">Leave Tracker Admin</td>
<td valign="top" width="10" style="border-bottom: 1px solid #cccccc; "><input type="checkbox" name="leavetracker" value='Y' <?php if($dbObject->getDbField('leavetracker')=="Y") { echo"checked"; } ?> /></td><td valign="top" style="border-bottom: 1px solid #cccccc; ">Leave Tracker</td>
<td valign="top" width="10" style="border-bottom: 1px solid #cccccc; "><input type="checkbox" name="courserecordadmin" value='Y' <?php if($dbObject->getDbField('courserecordadmin')=="Y") { echo"checked"; } ?> /></td><td valign="top" style="border-bottom: 1px solid #cccccc; ">Course Records Admin</td>
<td valign="top" width="10"><input type="checkbox" name="oral" value='Y' <?php if($dbObject->getDbField('oral')=="Y") { echo"checked"; } ?> /></td><td valign="top" style="border-bottom: 1px solid #cccccc;">Oral</td>
</tr>
<tr>
<td valign="top" width="10" style="border-bottom: 1px solid #cccccc; "><input type="checkbox" name="courserecord" value='Y' <?php if($dbObject->getDbField('courserecord')=="Y") { echo"checked"; } ?> /></td><td valign="top" style="border-bottom: 1px solid #cccccc; ">Course Records</td>
<td valign="top" width="10" style="border-bottom: 1px solid #cccccc; "><input type="checkbox" name="pauadmin" value='Y' <?php if($dbObject->getDbField('pauadmin')=="Y") { echo"checked"; } ?> /></td><td valign="top" style="border-bottom: 1px solid #cccccc; ">Procedures and
Updates Admin</td>
<td valign="top" width="10" style="border-bottom: 1px solid #cccccc; "><input type="checkbox" name="pau" value='Y' <?php if($dbObject->getDbField('pau')=="Y") { echo"checked"; } ?> /></td><td valign="top" style="border-bottom: 1px solid #cccccc; ">Procedures and
Updates</td>
<td valign="top" width="10"><input type="checkbox" name="oral_admin" value='Y' <?php if($dbObject->getDbField('oral_admin')=="Y") { echo"checked"; } ?> /></td><td valign="top" style="border-bottom: 1px solid #cccccc;">Admin-Oral</td>
</tr>
<tr>
<td valign="top" width="10" style="border-bottom: 1px solid #cccccc; "><input type="checkbox" name="workshops_admin" value='Y' <?php if($dbObject->getDbField('workshops_admin')=="Y") { echo"checked"; } ?> /></td><td valign="top" style="border-bottom: 1px solid #cccccc; ">Workshops Admin</td>
<td valign="top" width="10" style="border-bottom: 1px solid #cccccc; "><input type="checkbox" name="workshops_trainee" value='Y' <?php if($dbObject->getDbField('workshops_trainee')=="Y") { echo"checked"; } ?> /></td><td valign="top" style="border-bottom: 1px solid #cccccc; ">Workshops Trainee</td>
<td valign="top" width="10" style="border-bottom: 1px solid #cccccc; "><input type="checkbox" name="workshops_trainer" value='Y' <?php if($dbObject->getDbField('workshops_trainer')=="Y") { echo"checked"; } ?> /></td><td valign="top" style="border-bottom: 1px solid #cccccc; ">Workshops Trainer</td>
<td valign="top" width="10" style="border-bottom: 1px solid #cccccc; "><input type="checkbox" name="general_leave" value='Y' <?php if($dbObject->getDbField('general_leave')=="Y") { echo"checked"; } ?> /></td><td valign="top" style="border-bottom: 1px solid #cccccc; ">General leave</td>
</tr>
<tr>
<td valign="top" width="10" style="border-bottom: 1px solid #cccccc; "><input type="checkbox" name="toutorials_forms" value='Y' <?php if($dbObject->getDbField('toutorials_forms')=="Y") { echo"checked"; } ?> /></td><td valign="top" style="border-bottom: 1px solid #cccccc; ">Tutorials and Forms</td>
<td valign="top" width="10" style="border-bottom: 1px solid #cccccc; "><input type="checkbox" name="admin_conveyance" value='Y' <?php if($dbObject->getDbField('admin_conveyance')=="Y") { echo"checked"; } ?> /></td><td valign="top" style="border-bottom: 1px solid #cccccc; ">Admin-Conveyance</td>
<td valign="top" width="10" style="border-bottom: 1px solid #cccccc; "><input type="checkbox" name="conveyance" value='Y' <?php if($dbObject->getDbField('conveyance')=="Y") { echo"checked"; } ?> /></td><td valign="top" style="border-bottom: 1px solid #cccccc; ">Conveyance</td>
</tr>
<tr>
<td valign="top" width="10" style="border-bottom: 1px solid #cccccc; "><input type="checkbox" name="fd_incenter" value='Y' <?php if($dbObject->getDbField('fd_incenter')=="Y") { echo"checked"; } ?> /></td><td valign="top" style="border-bottom: 1px solid #cccccc; ">In-Center</td>
<td valign="top" width="10" style="border-bottom: 1px solid #cccccc; "><input type="checkbox" name="fd_payment_gateway" value='Y' <?php if($dbObject->getDbField('fd_payment_gateway')=="Y") { echo"checked"; } ?> /></td><td valign="top" style="border-bottom: 1px solid #cccccc; ">Payment gateway</td>
<td valign="top" width="10" style="border-bottom: 1px solid #cccccc; "><input type="checkbox" name="fd_reports" value='Y' <?php if($dbObject->getDbField('fd_reports')=="Y") { echo"checked"; } ?> /></td><td valign="top" style="border-bottom: 1px solid #cccccc; ">FD-reports</td>
</tr>
<tr>
<td valign="top" width="10"><input type="checkbox" name="incenter_admin" value='Y' <?php if($dbObject->getDbField('incenter_admin')=="Y") { echo"checked"; } ?> /></td><td valign="top" >Admin-In-Center</td>
<td valign="top"><input type="checkbox" name="calendar_admin" value='Y' <?php if($dbObject->getDbField('calendar_admin')=="Y") { echo"checked"; } ?> /><br><br>
<input type="checkbox" name="calendar_super_admin" value='Y' <?php if($dbObject->getDbField('calendar_super_admin')=="Y") { echo"checked"; } ?> />
</td><td valign="top">Admin-Calendar <br>OR<br>Super Admin-Calendar</td>
<td valign="top"><input type="checkbox" name="calendar" value='Y' <?php if($dbObject->getDbField('calendar')=="Y") { echo"checked"; } ?> /></td><td valign="top">Calendar</td>
</tr>
</table>
</td></tr>
<tr><td colspan='2'><input type='submit' name='aC' value='<?php echo $currentMode;?>'></td></tr>
</table>
</form>
<?php
function timings($start,$end,$selected_array)
{
$k=0;
for($i=$start;$i<=$end;$i=$i+0.5)
{
$j=$k%2;
if($j==0)
{
$k1=number_format($i,2);
}
else
{
$k2=$i-0.20;
$k1=number_format($k2,2);
}
$a.="<option value='".$k1."' ";
if(in_array($k1,$selected_array))
{
$a.=" selected";
}
$a.=">".$k1."</option>";
$k=$k+1;
}
return $a;
}
?>
<?php
include("footer_indeed.php");
?>
<script type='text/javascript'>//<![CDATA[
$(window).load(function(){
var target = $("#target");
$("#select")
.multiselect()
.bind("multiselectclick multiselectcheckall multiselectuncheckall", function( event, ui ){
// the getChecked method returns an array of DOM elements.
// map over them to create a new array of just the values.
// you could also do this by maintaining your own array of
// checked/unchecked values, but this is just as easy.
var checkedValues = $.map($(this).multiselect("getChecked"), function( input ){
return input.value;
});
// update the target based on how many are checked
target.val(
checkedValues.length
? checkedValues.join(', ')
: ''
);
})
.triggerHandler("multiselectclick"); // trigger above logic when page first loads
});//]]>
$(window).load(function(){
var target = $("#target_mon");
$("#target_mon1")
.multiselect()
.bind("multiselectclick multiselectcheckall multiselectuncheckall", function( event, ui ){
// the getChecked method returns an array of DOM elements.
// map over them to create a new array of just the values.
// you could also do this by maintaining your own array of
// checked/unchecked values, but this is just as easy.
var checkedValues = $.map($(this).multiselect("getChecked"), function( input ){
return input.value;
});
// update the target based on how many are checked
target.val(
checkedValues.length
? checkedValues.join(', ')
: ''
);
})
.triggerHandler("multiselectclick"); // trigger above logic when page first loads
});//]]>
$(window).load(function(){
var target = $("#target_tue");
$("#target_tue1")
.multiselect()
.bind("multiselectclick multiselectcheckall multiselectuncheckall", function( event, ui ){
// the getChecked method returns an array of DOM elements.
// map over them to create a new array of just the values.
// you could also do this by maintaining your own array of
// checked/unchecked values, but this is just as easy.
var checkedValues = $.map($(this).multiselect("getChecked"), function( input ){
return input.value;
});
// update the target based on how many are checked
target.val(
checkedValues.length
? checkedValues.join(', ')
: ''
);
})
.triggerHandler("multiselectclick"); // trigger above logic when page first loads
});//]]>
$(window).load(function(){
var target = $("#target_wed");
$("#target_wed1")
.multiselect()
.bind("multiselectclick multiselectcheckall multiselectuncheckall", function( event, ui ){
// the getChecked method returns an array of DOM elements.
// map over them to create a new array of just the values.
// you could also do this by maintaining your own array of
// checked/unchecked values, but this is just as easy.
var checkedValues = $.map($(this).multiselect("getChecked"), function( input ){
return input.value;
});
// update the target based on how many are checked
target.val(
checkedValues.length
? checkedValues.join(', ')
: ''
);
})
.triggerHandler("multiselectclick"); // trigger above logic when page first loads
});//]]>
$(window).load(function(){
var target = $("#target_thu");
$("#target_thu1")
.multiselect()
.bind("multiselectclick multiselectcheckall multiselectuncheckall", function( event, ui ){
// the getChecked method returns an array of DOM elements.
// map over them to create a new array of just the values.
// you could also do this by maintaining your own array of
// checked/unchecked values, but this is just as easy.
var checkedValues = $.map($(this).multiselect("getChecked"), function( input ){
return input.value;
});
// update the target based on how many are checked
target.val(
checkedValues.length
? checkedValues.join(', ')
: ''
);
})
.triggerHandler("multiselectclick"); // trigger above logic when page first loads
});//]]>
$(window).load(function(){
var target = $("#target_fri");
$("#target_fri1")
.multiselect()
.bind("multiselectclick multiselectcheckall multiselectuncheckall", function( event, ui ){
// the getChecked method returns an array of DOM elements.
// map over them to create a new array of just the values.
// you could also do this by maintaining your own array of
// checked/unchecked values, but this is just as easy.
var checkedValues = $.map($(this).multiselect("getChecked"), function( input ){
return input.value;
});
// update the target based on how many are checked
target.val(
checkedValues.length
? checkedValues.join(', ')
: ''
);
})
.triggerHandler("multiselectclick"); // trigger above logic when page first loads
});//]]>
$(window).load(function(){
var target = $("#target_sat");
$("#target_sat1")
.multiselect()
.bind("multiselectclick multiselectcheckall multiselectuncheckall", function( event, ui ){
// the getChecked method returns an array of DOM elements.
// map over them to create a new array of just the values.
// you could also do this by maintaining your own array of
// checked/unchecked values, but this is just as easy.
var checkedValues = $.map($(this).multiselect("getChecked"), function( input ){
return input.value;
});
// update the target based on how many are checked
target.val(
checkedValues.length
? checkedValues.join(', ')
: ''
);
})
.triggerHandler("multiselectclick"); // trigger above logic when page first loads
});//]]>
$(window).load(function(){
var target = $("#target_sun");
$("#target_sun1")
.multiselect()
.bind("multiselectclick multiselectcheckall multiselectuncheckall", function( event, ui ){
// the getChecked method returns an array of DOM elements.
// map over them to create a new array of just the values.
// you could also do this by maintaining your own array of
// checked/unchecked values, but this is just as easy.
var checkedValues = $.map($(this).multiselect("getChecked"), function( input ){
return input.value;
});
// update the target based on how many are checked
target.val(
checkedValues.length
? checkedValues.join(', ')
: ''
);
})
.triggerHandler("multiselectclick"); // trigger above logic when page first loads
});//]]>
function checkuncheck(checkid,targetid)
{
if ($('#'+checkid+'').attr('checked')) {
$('#'+targetid+'').removeAttr("disabled", "true");
}
}
</script>