if($_GET['iddirs']=="")$_GET['iddirs']=$_SESSION['email_iddir'];
print display_dir_data_email(0,"",$_SESSION['authenticated_user_id'],$_GET['target'],$_GET['tab']);?> |
////////////////////////EcmContracts/////////////////////////
if($_GET['tab']=="EcmContracts" or $_GET['tab']=="All")
{
if(!$_GET['ecmcontract_start'])$_GET['ecmcontract_start']=0;
$il=10;
if($_GET['ecmcontract_start']==0 || $_GET['ecmcontract_start']=="")
{
if(!$ecmcontractsw)$_SESSION['ecmcontract_where']="id='xxx'";
else $_SESSION['ecmcontract_where']=$ecmcontractsw;
}
if(!$_GET['ecmcontracts_order_by'])$ecmcontracts_order_by="date_entered";
else $ecmcontracts_order_by=$_GET['ecmcontracts_order_by'];
if(!$_GET['ecmcontracts_sorder']){$_GET['ecmcontracts_sorder']="desc";$ecmcontracts_sorder="asc";}
elseif($_GET['ecmcontracts_sorder']=="asc")$ecmcontracts_sorder="desc";
elseif($_GET['ecmcontracts_sorder']=="desc")$ecmcontracts_sorder="asc";
$z="select distinct * from ecmcontracts where ".$_SESSION['ecmcontract_where']." order by ".$ecmcontracts_order_by." ".$_GET['ecmcontracts_sorder']." limit ".$_GET['ecmcontract_start'].",".$il;
$w=mysql_query($z);
$ile=mysql_num_rows(mysql_query("select distinct id from ecmcontracts where ".$_SESSION['ecmcontract_where']." order by name"));
if($ile<$il)$ilenastronie=$ile;
else $ilenastronie=$il;
$od=$_GET['ecmcontract_start']+1;
$do=$od+$il-1;
$endl=floor($ile/$il);
$endl=$endl*$il;
if($ile==0)$od=0;
if($_GET['ecmcontract_start']+$il>=$ile)$do=$ile;
if($ile==0 || $ile<=$il)
{
$start=' ';
$end=' ';
$previous=' ';
$next=' ';
}
else
{
if($_GET['ecmcontract_start']==0)
{
$start=' ';
$previous=' ';
$end='';
$nextl=$_GET['ecmcontract_start']+$il;
$next='';
}
if($_GET['ecmcontract_start']>0 && $_GET['ecmcontract_start']<$ile)
{
$start='';
$end='';
$nextl=$_GET['ecmcontract_start']+$il;
$next='';
$previousl=$_GET['ecmcontract_start']-$il;
$previous='';
}
if($_GET['ecmcontract_start']+$il>=$ile)
{
$start='';
$end=' ';
$next=' ';
$previousl=$_GET['ecmcontract_start']-$il;
$previous='';
}
}
print 'Contracts List |  | ';
}
////////////////////////EcmCorrespondenceIns/////////////////////////
if($_GET['tab']=="EcmCorrespondenceIns" or $_GET['tab']=="All")
{
if(!$_GET['ecmcorrespondencein_start'])$_GET['ecmcorrespondencein_start']=0;
$il=10;
if($_GET['ecmcorrespondencein_start']==0 || $_GET['ecmcorrespondencein_start']=="")
{
if(!$ecmcorrespondenceinsw)$_SESSION['ecmcorrespondencein_where']="id='xxx'";
else $_SESSION['ecmcorrespondencein_where']=$ecmcorrespondenceinsw;
}
if(!$_GET['ecmcorrespondenceins_order_by'])$ecmcorrespondenceins_order_by="date_entered";
else $ecmcorrespondenceins_order_by=$_GET['ecmcorrespondenceins_order_by'];
if(!$_GET['ecmcorrespondenceins_sorder']){$_GET['ecmcorrespondenceins_sorder']="desc";$ecmcorrespondenceins_sorder="asc";}
elseif($_GET['ecmcorrespondenceins_sorder']=="asc")$ecmcorrespondenceins_sorder="desc";
elseif($_GET['ecmcorrespondenceins_sorder']=="desc")$ecmcorrespondenceins_sorder="asc";
$z="select distinct * from ecmcorrespondenceins where ".$_SESSION['ecmcorrespondencein_where']." order by ".$ecmcorrespondenceins_order_by." ".$_GET['ecmcorrespondenceins_sorder']." limit ".$_GET['ecmcorrespondencein_start'].",".$il;
$w=mysql_query($z);
$ile=mysql_num_rows(mysql_query("select distinct id from ecmcorrespondenceins where ".$_SESSION['ecmcorrespondencein_where']." order by name"));
if($ile<$il)$ilenastronie=$ile;
else $ilenastronie=$il;
$od=$_GET['ecmcorrespondencein_start']+1;
$do=$od+$il-1;
$endl=floor($ile/$il);
$endl=$endl*$il;
if($ile==0)$od=0;
if($_GET['ecmcorrespondencein_start']+$il>=$ile)$do=$ile;
if($ile==0 || $ile<=$il)
{
$start=' ';
$end=' ';
$previous=' ';
$next=' ';
}
else
{
if($_GET['ecmcorrespondencein_start']==0)
{
$start=' ';
$previous=' ';
$end='';
$nextl=$_GET['ecmcorrespondencein_start']+$il;
$next='';
}
if($_GET['ecmcorrespondencein_start']>0 && $_GET['ecmcorrespondencein_start']<$ile)
{
$start='';
$end='';
$nextl=$_GET['ecmcorrespondencein_start']+$il;
$next='';
$previousl=$_GET['ecmcorrespondencein_start']-$il;
$previous='';
}
if($_GET['ecmcorrespondencein_start']+$il>=$ile)
{
$start='';
$end=' ';
$next=' ';
$previousl=$_GET['ecmcorrespondencein_start']-$il;
$previous='';
}
}
print 'Correspondence In List |  | ';
}
////////////////////////EcmCorrespondenceOuts/////////////////////////
if($_GET['tab']=="EcmCorrespondenceOuts" or $_GET['tab']=="All")
{
if(!$_GET['ecmcorrespondenceout_start'])$_GET['ecmcorrespondenceout_start']=0;
$il=10;
if($_GET['ecmcorrespondenceout_start']==0 || $_GET['ecmcorrespondenceout_start']=="")
{
if(!$ecmcorrespondenceoutsw)$_SESSION['ecmcorrespondenceout_where']="id='xxx'";
else $_SESSION['ecmcorrespondenceout_where']=$ecmcorrespondenceoutsw;
}
if(!$_GET['ecmcorrespondenceouts_order_by'])$ecmcorrespondenceouts_order_by="date_entered";
else $ecmcorrespondenceouts_order_by=$_GET['ecmcorrespondenceouts_order_by'];
if(!$_GET['ecmcorrespondenceouts_sorder']){$_GET['ecmcorrespondenceouts_sorder']="desc";$ecmcorrespondenceouts_sorder="asc";}
elseif($_GET['ecmcorrespondenceouts_sorder']=="asc")$ecmcorrespondenceouts_sorder="desc";
elseif($_GET['ecmcorrespondenceouts_sorder']=="desc")$ecmcorrespondenceouts_sorder="asc";
$z="select distinct * from ecmcorrespondenceouts where ".$_SESSION['ecmcorrespondenceout_where']." order by ".$ecmcorrespondenceouts_order_by." ".$_GET['ecmcorrespondenceouts_sorder']." limit ".$_GET['ecmcorrespondenceout_start'].",".$il;
$w=mysql_query($z);
$ile=mysql_num_rows(mysql_query("select distinct id from ecmcorrespondenceouts where ".$_SESSION['ecmcorrespondenceout_where']." order by name"));
if($ile<$il)$ilenastronie=$ile;
else $ilenastronie=$il;
$od=$_GET['ecmcorrespondenceout_start']+1;
$do=$od+$il-1;
$endl=floor($ile/$il);
$endl=$endl*$il;
if($ile==0)$od=0;
if($_GET['ecmcorrespondenceout_start']+$il>=$ile)$do=$ile;
if($ile==0 || $ile<=$il)
{
$start=' ';
$end=' ';
$previous=' ';
$next=' ';
}
else
{
if($_GET['ecmcorrespondenceout_start']==0)
{
$start=' ';
$previous=' ';
$end='';
$nextl=$_GET['ecmcorrespondenceout_start']+$il;
$next='';
}
if($_GET['ecmcorrespondenceout_start']>0 && $_GET['ecmcorrespondenceout_start']<$ile)
{
$start='';
$end='';
$nextl=$_GET['ecmcorrespondenceout_start']+$il;
$next='';
$previousl=$_GET['ecmcorrespondenceout_start']-$il;
$previous='';
}
if($_GET['ecmcorrespondenceout_start']+$il>=$ile)
{
$start='';
$end=' ';
$next=' ';
$previousl=$_GET['ecmcorrespondenceout_start']-$il;
$previous='';
}
}
print 'Correspondence Out List |  |
';
}
////////////////////////EcmInvoiceIns/////////////////////////
if($_GET['tab']=="EcmInvoiceIns" or $_GET['tab']=="All")
{
if(!$_GET['ecminvoicein_start'])$_GET['ecminvoicein_start']=0;
$il=10;
if($_GET['ecminvoicein_start']==0 || $_GET['ecminvoicein_start']=="")
{
if(!$ecminvoiceinsw)$_SESSION['ecminvoicein_where']="id='xxx'";
else $_SESSION['ecminvoicein_where']=$ecminvoiceinsw;
}
if(!$_GET['ecminvoiceins_order_by'])$ecminvoiceins_order_by="date_entered";
else $ecminvoiceins_order_by=$_GET['ecminvoiceins_order_by'];
if(!$_GET['ecminvoiceins_sorder']){$_GET['ecminvoiceins_sorder']="desc";$ecminvoiceins_sorder="asc";}
elseif($_GET['ecminvoiceins_sorder']=="asc")$ecminvoiceins_sorder="desc";
elseif($_GET['ecminvoiceins_sorder']=="desc")$ecminvoiceins_sorder="asc";
$z="select distinct * from ecminvoiceins where ".$_SESSION['ecminvoicein_where']." order by ".$ecminvoiceins_order_by." ".$_GET['ecminvoiceins_sorder']." limit ".$_GET['ecminvoicein_start'].",".$il;
$w=mysql_query($z);
$ile=mysql_num_rows(mysql_query("select distinct id from ecminvoiceins where ".$_SESSION['ecminvoicein_where']." order by name"));
if($ile<$il)$ilenastronie=$ile;
else $ilenastronie=$il;
$od=$_GET['ecminvoicein_start']+1;
$do=$od+$il-1;
$endl=floor($ile/$il);
$endl=$endl*$il;
if($ile==0)$od=0;
if($_GET['ecminvoicein_start']+$il>=$ile)$do=$ile;
if($ile==0 || $ile<=$il)
{
$start=' ';
$end=' ';
$previous=' ';
$next=' ';
}
else
{
if($_GET['ecminvoicein_start']==0)
{
$start=' ';
$previous=' ';
$end='';
$nextl=$_GET['ecminvoicein_start']+$il;
$next='';
}
if($_GET['ecminvoicein_start']>0 && $_GET['ecminvoicein_start']<$ile)
{
$start='';
$end='';
$nextl=$_GET['ecminvoicein_start']+$il;
$next='';
$previousl=$_GET['ecminvoicein_start']-$il;
$previous='';
}
if($_GET['ecminvoicein_start']+$il>=$ile)
{
$start='';
$end=' ';
$next=' ';
$previousl=$_GET['ecminvoicein_start']-$il;
$previous='';
}
}
print 'Invoice In List |  | ';
}
////////////////////////EcmInvoiceOuts/////////////////////////
if($_GET['tab']=="EcmInvoiceOuts" or $_GET['tab']=="All")
{
if(!$_GET['ecminvoiceout_start'])$_GET['ecminvoiceout_start']=0;
$il=10;
if($_GET['ecminvoiceout_start']==0 || $_GET['ecminvoiceout_start']=="")
{
if(!$ecminvoiceoutsw)$_SESSION['ecminvoiceout_where']="id='xxx'";
else $_SESSION['ecminvoiceout_where']=$ecminvoiceoutsw;
}
if(!$_GET['ecminvoiceouts_order_by'])$ecminvoiceouts_order_by="date_entered";
else $ecminvoiceouts_order_by=$_GET['ecminvoiceouts_order_by'];
if(!$_GET['ecminvoiceouts_sorder']){$_GET['ecminvoiceouts_sorder']="desc";$ecminvoiceouts_sorder="asc";}
elseif($_GET['ecminvoiceouts_sorder']=="asc")$ecminvoiceouts_sorder="desc";
elseif($_GET['ecminvoiceouts_sorder']=="desc")$ecminvoiceouts_sorder="asc";
$z="select distinct * from ecminvoiceouts where ".$_SESSION['ecminvoiceout_where']." order by ".$ecminvoiceouts_order_by." ".$_GET['ecminvoiceouts_sorder']." limit ".$_GET['ecminvoiceout_start'].",".$il;
$w=mysql_query($z);
$ile=mysql_num_rows(mysql_query("select distinct id from ecminvoiceouts where ".$_SESSION['ecminvoiceout_where']." order by name"));
if($ile<$il)$ilenastronie=$ile;
else $ilenastronie=$il;
$od=$_GET['ecminvoiceout_start']+1;
$do=$od+$il-1;
$endl=floor($ile/$il);
$endl=$endl*$il;
if($ile==0)$od=0;
if($_GET['ecminvoiceout_start']+$il>=$ile)$do=$ile;
if($ile==0 || $ile<=$il)
{
$start=' ';
$end=' ';
$previous=' ';
$next=' ';
}
else
{
if($_GET['ecminvoiceout_start']==0)
{
$start=' ';
$previous=' ';
$end='';
$nextl=$_GET['ecminvoiceout_start']+$il;
$next='';
}
if($_GET['ecminvoiceout_start']>0 && $_GET['ecminvoiceout_start']<$ile)
{
$start='';
$end='';
$nextl=$_GET['ecminvoiceout_start']+$il;
$next='';
$previousl=$_GET['ecminvoiceout_start']-$il;
$previous='';
}
if($_GET['ecminvoiceout_start']+$il>=$ile)
{
$start='';
$end=' ';
$next=' ';
$previousl=$_GET['ecminvoiceout_start']-$il;
$previous='';
}
}
print 'Invoice Out List |  |
';
}
////////////////////////EcmDocs/////////////////////////
if($_GET['tab']=="EcmDocs" or $_GET['tab']=="All")
{
if(!$_GET['ecmdoc_start'])$_GET['ecmdoc_start']=0;
$il=10;
if($_GET['ecmdoc_start']==0 || $_GET['ecmdoc_start']=="")
{
if(!$ecmdocsw)$_SESSION['ecmdoc_where']="id='xxx'";
else $_SESSION['ecmdoc_where']=$ecmdocsw;
}
if(!$_GET['ecmdocs_order_by'])$ecmdocs_order_by="date_entered";
else $ecmdocs_order_by=$_GET['ecmdocs_order_by'];
if(!$_GET['ecmdocs_sorder']){$_GET['ecmdocs_sorder']="desc";$ecmdocs_sorder="asc";}
elseif($_GET['ecmdocs_sorder']=="asc")$ecmdocs_sorder="desc";
elseif($_GET['ecmdocs_sorder']=="desc")$ecmdocs_sorder="asc";
$z="select distinct * from ecmdocs where ".$_SESSION['ecmdoc_where']." order by ".$ecmdocs_order_by." ".$_GET['ecmdocs_sorder']." limit ".$_GET['ecmdoc_start'].",".$il;
$w=mysql_query($z);
$ile=mysql_num_rows(mysql_query("select distinct id from ecmdocs where ".$_SESSION['ecmdoc_where']." order by ".$ecmdocs_order_by." ".$ecmdocs_sorder));
if($ile<$il)$ilenastronie=$ile;
else $ilenastronie=$il;
$od=$_GET['ecmdoc_start']+1;
$do=$od+$il-1;
$endl=floor($ile/$il);
$endl=$endl*$il;
if($ile==0)$od=0;
if($_GET['ecmdoc_start']+$il>=$ile)$do=$ile;
if($ile==0 || $ile<=$il)
{
$start=' ';
$end=' ';
$previous=' ';
$next=' ';
}
else
{
if($_GET['ecmdoc_start']==0)
{
$start=' ';
$previous=' ';
$end='';
$nextl=$_GET['ecmdoc_start']+$il;
$next='';
}
if($_GET['ecmdoc_start']>0 && $_GET['ecmdoc_start']<$ile)
{
$start='';
$end='';
$nextl=$_GET['ecmdoc_start']+$il;
$next='';
$previousl=$_GET['ecmdoc_start']-$il;
$previous='';
}
if($_GET['ecmdoc_start']+$il>=$ile)
{
$start='';
$end=' ';
$next=' ';
$previousl=$_GET['ecmdoc_start']-$il;
$previous='';
}
}
print 'Files List |  |
|
|
| Name |
Registered On |
Account |
Version |
Assigned |
User |
';
while($r=mysql_fetch_array($w))
{
$rr=mysql_fetch_array(mysql_query("select id,name from ecmfiles_versions where file_id='".$r['file_id']."'"));
$filename=$rr['name'];
$ext=explode(".",$filename);
$roz=$ext[count($ext)-1];
$fname=$r['name'].".".$roz;
print '
|
'.cut_name_in_search($r['name'],20).' |
'.$r['date_entered'][0].$r['date_entered'][1].$r['date_entered'][2].$r['date_entered'][3].$r['date_entered'][4].$r['date_entered'][5].$r['date_entered'][6].$r['date_entered'][7].$r['date_entered'][8].$r['date_entered'][9].' |
|
|
|
'.get_assigned_user_name_in_search($r['assigned_user_id']).' |
|
';
}
print ' ';
}
mysql_close($sql);
?> |