
	 <?php
	   include'connection.php';
	   include'time.php';
	   
	   echo "<a href='view_payment1.php' target='_blank'><div class='imgdiv'>
	    <img src='payment.png'></img>";
	  
	   $quGetPay="select * from paymentreq where Active='0'";
	   $reGetPay=mysqli_query($con,$quGetPay);
	   $pay=mysqli_num_rows($reGetPay);
	  
	   if($pay>=1)
	   {
	        echo "<a href='view_payment1.php' target='_blank'><div id='notifidiv'>". $pay."</div></a>";
	   }
	 
	   echo "</div></a>
	   
	   <a href='Payment_Settled_List.php' target='_blank'><div class='imgdiv'>
	    <img src='../settle.png'></img>";
	  
	   $quSettle="SELECT * FROM paymentreq WHERE Active='1' AND SettleStatus='PENDING'";
	   $reSettle=mysqli_query($con,$quSettle);
	   $Settle=mysqli_num_rows($reSettle);
	  
	   if($Settle>=1)
	   {
	        echo "<a href='Payment_Settled_List.php' target='_blank'><div id='notifidiv'>". $Settle."</div></a>";
	   }
	 
	   echo "</div></a>
	   
	  
	   <a href='list_complain.php' target='_blank'><div class='imgdiv'>
	    <img src='complain.png'></img>";
	   	
	   $quGetComp="select * from complain where Active='0'";
	   $reGetComp=mysqli_query($con,$quGetComp);
	   $comp=mysqli_num_rows($reGetComp);
	  
	   if($comp>=1)
	   {
	        echo "<a href='list_complain.php' target='_blank'><div id='notifidiv'>". $comp."</div></a>";
	   }
	   
	   echo "</div></a>
	
	  
	   <a href='contact_us.php' target='_blank'><div class='imgdiv'>
	    <img src='msg.png'></img>";
	    
       $quGetMsg="select * from contactus where Active='0'";
	   $reGetMsg=mysqli_query($con,$quGetMsg);
	   $msg=mysqli_num_rows($reGetMsg);
	   if($msg>=1)
	   {
	        echo "<a href='contact_us.php' target='_blank'><div id='notifidiv'>". $msg."</div></a>";
	   }
	   
	   echo "</div></a>
	   
	  
	   <a href='pending_recharge.php' target='_blank'><div class='imgdiv'>
	    <img src='waiting.png'></img>";
	        $Pdate = date("Y-m-d H:i:s");
            $Ptime = strtotime($Pdate);
            $Ptime = $Ptime - (3 * 60);
            $PdatePtime = date("Y-m-d H:i:s", $Ptime);
            
    	    $quGetWaitRech="select * from recharge where Rechargedate='$date' and PTime<='$PdatePtime' and Status='PENDING'";
	        $reGetWaitRech=mysqli_query($con,$quGetWaitRech);
	        $waitRech=mysqli_num_rows($reGetWaitRech);
	        if($waitRech>=1)
	        {
	              echo "<a href='pending_recharge.php' target='_blank'><div id='notifidiv'>". $waitRech."</div></a>";
	        }
	   
	 
	   echo "</div></a>
	   
	   <a href='Duplicate_Refund.php' target='_blank'><div class='imgdiv'>
	    <img src='Duplicate_Payment.png'></img>";
	    
    	    $quGetDupRef="select Paynrechid, count(Paynrechid) from wallet where Transactiontype='Recharge_Refund' and ActiveRefund='0' group By Paynrechid having Count(Paynrechid)>1;";
	        $reGetDupRef=mysqli_query($con,$quGetDupRef);
	        $DupRef=mysqli_num_rows($reGetDupRef);
	        if($DupRef>=1)
	        {
	              echo "<a href='Duplicate_Refund.php' target='_blank'><div id='notifidiv'>". $DupRef."</div></a>";
	        }
	   
	   echo "</div></a>
	   
	   <a href='Wrong_Refund.php' target='_blank'><div class='imgdiv'><img src='zigzag.png'></img></div></a>
	   <a href='MinusDiff.php' target='_blank'><div class='imgdiv'>
	    <img src='loss1.png'></img>";
	        $date = date("Y-m-d H:i:s");
    	    $quGetMinusDiff="select * from recharge where Diff<-5 and ActiveMinus=0";
	        $reGetMinusDiff=mysqli_query($con,$quGetMinusDiff);
	        $MinusDiff=mysqli_num_rows($reGetMinusDiff);
	        if($MinusDiff>=1)
	        {
	              echo "<a href='MinusDiff.php' target='_blank'><div id='notifidiv'>".$MinusDiff."</div></a>";
	        }
	   
	 
	   echo "</div></a>";
	   ?>
    