<?php   
	include_once("../view/header-footer/header.php");  
?>  
  
  
    <style>
			body {
				font-family: 'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;
				text-align: center;
				color: #777;
			}

			body h1 {
				font-weight: 300;
				margin-bottom: 0px;
				padding-bottom: 0px;
				color: #000;
			}

			body h3 {
				font-weight: 300;
				margin-top: 10px;
				margin-bottom: 20px;
				font-style: italic;
				color: #555;
			}

			body a {
				color: #06f;
			}
            .logoInvoice{
                width: 90px;
                height:90px;
                display: inline-flex;
                background: #0078fd;
                border-radius: 50%;
                overflow: hidden; 
                padding: 10px;
            }
			.invoice-box {
				max-width: 100%;
				margin: auto;
				padding: 16px;
				border: 1px solid #eee;
				box-shadow: 0 0 10px rgba(0, 0, 0, 0.15);
				font-size: 12px;
				line-height: 24px;
				font-family: 'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;
				color: #555;
			}

			.invoice-box table {
				width: 100%;
				line-height: inherit;
				text-align: left;
				border-collapse: collapse;
			}
			.colorText{
		        color: #3fc43b;
			}
			.boldText{
			    font-weight:bold;
			}

			.invoice-box table td {
				padding: 7px 0;
				vertical-align: top;
				font-size:14px;
			}

			.invoice-box table tr td:nth-child(2) {
				text-align: right;
			}

			.invoice-box table tr.top table td {
				padding-bottom: 20px;
			}

			.invoice-box table tr.top table td.title {
			    font-size: 11px;
                line-height: 30px;
                color: #333;
                padding-bottom: 6px;
                    padding-top: 0;
			}

			.invoice-box table tr.information table td {
				padding-bottom: 40px;
			}

			.invoice-box table tr.heading td {
				background: #eee;
				border-bottom: 1px solid #ddd;
				font-weight: bold;
			}

			.invoice-box table tr.details td {
				padding-bottom: 20px;
			}

			.invoice-box table tr.item td {
				border-top: 1px solid #eee;
			}

			.invoice-box table tr.item.last td {
				border-bottom: none;
			}

			.invoice-box table tr.total td:nth-child(2) {
				border-top: 2px solid #eee;
				font-weight: bold;
			}
			.printBtn{
			    display: flex;
                justify-content: space-between;
			}
			.printBtn .btn{
			    width: 47.5%;
			}
			
            .printBtn .lightBtn {
                width: 47.5%;
                background: #d6d6d6 !important;
                color: #636363 !important;
            }
            
        /*Kailas Css*/
        .withdrawaltimeline {
            width: 100%;
            float: left;
            text-align: left;
            margin-top: 20px;
      }
      .withdrawaltimeline h1 {
        font-size: 14px;
        font-weight: 600;
        color: #333;
        margin-bottom: 0;
      }
      .withdrawaltimeline .history-tl-container {
        margin: auto;
        display: block;
        position: relative;
      }
      .withdrawaltimeline .history-tl-container ul.tl {
        margin: 20px 0 0;
        padding: 0;
        display: inline-block;
        width: 100%;
      }
      .withdrawaltimeline .history-tl-container ul.tl li {
        list-style: none;
        margin: auto;
        margin-left: 10px;
        min-height: 50px;
        border-left: 1px dashed #86d6ff;
        padding: 0 0 25px 30px;
        position: relative;
      }
      .withdrawaltimeline .history-tl-container ul.tl li:last-child {
        border-left: 0;
        padding-bottom: 0;
      }
      .withdrawaltimeline .history-tl-container ul.tl li::before {
        position: absolute;
        left: -10px;
        top: 2px;
        content: " ";
        border: 8px solid rgba(255, 255, 255, 0.74);
        border-radius: 100%;
        background: #258cc7;
        height: 20px;
        width: 20px;
        transition: all 500ms ease-in-out;
      }
      .withdrawaltimeline .history-tl-container ul.tl li:hover::before {
        border-color: #258cc7;
        transition: all 1000ms ease-in-out;
      }
      .withdrawaltimeline ul.tl li .item-title {
        font-size: 13px;
        font-weight: 700;
        color: #333;
      }
      .withdrawaltimeline ul.tl li .item-detail {
        color: rgba(0, 0, 0, 0.5);
        font-size: 12px;
        font-weight: 500;
      }
      .withdrawaltimeline ul.tl li .timestamp {
        color: #8d8d8d;
        position: absolute;
        width: 100px;
        left: -50%;
        text-align: right;
        font-size: 12px;
      }
      .activeSubmitted::before {
        border: 8px solid rgb(35 168 14 / 74%) !important;
        background: #fff !important;
      }
      .activeAcceped::before {
        border: 8px solid rgb(229 68 17 / 74%) !important;
        background: #fff !important;
      }
            /*End*/

			@media only screen and (max-width: 600px) {
				.invoice-box table tr.top table td {
					width: 100%;
					display: block;
					text-align: center;
				}

				.invoice-box table tr.information table td {
					width: 100%;
					display: block;
					text-align: center;
				}
			}
</style>
  
   <!-- Features -->
   <div class="innerDeader">
       
       <?php 
       
        if($FResult->type==7) 
	    {
        if($accountSet==1) 
        {
       ?>
      <div class="container">
          <!--a href="javascript:void(0);" id="go-back">Go Back</a-->
          <h5>Withdraw Request Submited</h5>
          <span>Your withdraw request for Rs <b> &#8377; <?php echo $FResult->amountPaid;?></b> has been submited. You will receive the amount till  <b> 10 <?php echo date("M Y");?></b></span><br>
		  <span> <?php echo date("d-M-Y");?></span>
     </div>    
     <?php }
        }
     ?>
   </div>
   <div class="innerBody">
       <div class="container">
         

		<div class="invoice-box">
			<table>
				<tbody><tr class="top">
					<td colspan="2">
						<table>
							<tbody><tr>
								<td class="title">
									<!--<img src="./A simple, clean, and responsive HTML invoice template_files/logo.png" alt="Company logo" style="width: 100%; max-width: 300px">-->
									<span class="logoInvoice">
									    <img src="<?php echo ROOTPATH;?>/images/logo.png" alt="logo">
									</span>
								</td>

								<!--td>
									Invoice #: 123<br>
									Created: January 1, 2023<br>
									Due: February 1, 2023
								</td-->
							</tr>
						</tbody>
						</table>
					</td>
				</tr>

				<!--tr class="information">
					<td colspan="2">
						<table>
							<tbody><tr>
								<td>
									Sparksuite, Inc.<br>
									12345 Sunny Road<br>
									Sunnyville, TX 12345
								</td>

								<td>
									Acme Corp.<br>
									John Doe<br>
									john@example.com
								</td>
							</tr>
						</tbody></table>
					</td>
				</tr=-->

				<tr class="">
					<td>Payment Type</td>  
					<td>
						<?php 
							 if($FResult->type==7) 
							{
								echo "Money Transfer";	
								$Bank = "Bank Transfer";
								
							    /*$stmt=$conn->prepare("select  status from  UI__TxnFailUsers  where cdId=:cdId ");   
                                $stmt->bindValue(':cdId',  ($_REQUEST['id']) , PDO::PARAM_STR);  
                                $stmt->execute(); 	 
                                $UI__TxnFailUsers = $stmt->fetch(PDO::FETCH_OBJ);
							    
							    
							    
							    $stmt=$conn->prepare("select  addDel from  UI__DebitCredit where id =:id ");   
                                $stmt->bindValue(':id',  ($_REQUEST['id']-1) , PDO::PARAM_STR);  
                                $stmt->execute(); 	
                                $UI__DebitCredit = $stmt->fetch(PDO::FETCH_OBJ);
                                $tpaid= $UI__DebitCredit->addDel;
							
								$stmt=$conn->prepare("select  byw from  UI__DebitCredit where id =:id ");   
                                $stmt->bindValue(':id',  $_REQUEST['id'] , PDO::PARAM_STR);  
                                $stmt->execute(); 
                                if($stmt->rowCount()>0)   
                                {
                                        $nmSelect = $stmt->fetch(PDO::FETCH_OBJ);
                                        $receiver = $nmSelect->byw;
                                         
                                        /*$stmt=$conn->prepare("select  nm  from  UI__Rgst where cuurentId =:cuurentId ");   
                                        $stmt->bindValue(':cuurentId', $nmSelect->custId , PDO::PARAM_STR);  
                                        $stmt->execute();  
                                        $nmSelect = $stmt->fetch(PDO::FETCH_OBJ);  
                                        $receiver = $nmSelect->nm;
                                }else
                                    $receiver = ""; */
                                   
                                    
                                 
                                $stmt=$conn->prepare("select  accName from  UI__AddAccount  where accno=:accno ");   
                                $stmt->bindValue(':accno',  $FResult->Topay , PDO::PARAM_STR);  
                                $stmt->execute(); 	 
                                $UI__AddAccount = $stmt->fetch(PDO::FETCH_OBJ);  
							    $receiver = $UI__AddAccount->accName;   
							}   
						?>
						 
					</td>
				</tr>

				<tr class="">
					<td>Bank</td> 
					<td><?php  echo $Bank;?></td>
				</tr> 

				<tr class="">
					<td>To</td> 
					<td><?php  echo $FResult->Topay;?></td>
				</tr> 
				
				<tr class="">
					<td>Receiver</td> 
					<td><?php echo $receiver;?></td>
				</tr> 

                
				<tr class="">
					<td>By Userid</td>  
				<td>
				    <?php   
                        $stmt=$conn->prepare("select byw  from  UI__DebitCredit where id =:id ");   
                        $stmt->bindValue(':id', $_REQUEST['id'] , PDO::PARAM_STR);  
                        $stmt->execute(); 
                        $nmSelect = $stmt->fetch(PDO::FETCH_OBJ);    
                        echo $nmSelect->byw;
		            ?>
			    </td>
				</tr>
				
				<tr class="">
					<td>By Name</td> 
					<td>
					<?php  
					
					 if($FResult->type==11) 
					 {
					     echo "Fund Credited By User";
					     
					 }else	if( ($FResult->type==4) || ($FResult->type==13)  || ($FResult->type==15) || ($FResult->type==2) ) 
				    {        
                        $stmt=$conn->prepare("select nm  from   UI__Rgst  where  cuurentId =:cuurentId ");   
                        $stmt->bindValue(':cuurentId', $nmSelect->byw , PDO::PARAM_STR);  
                        $stmt->execute(); 
                        $nmSelect = $stmt->fetch(PDO::FETCH_OBJ);   
                        echo $nmSelect->nm;
                                
					}else	if($FResult->type==5) 
					{
                        $stmt=$conn->prepare("select  nm  from  UI__Rgst where cuurentId =:cuurentId ");   
                        $stmt->bindValue(':cuurentId', $FResult->Topay , PDO::PARAM_STR);  
                        $stmt->execute();  
                        $nmSelect = $stmt->fetch(PDO::FETCH_OBJ);  
                        echo $nmSelect->nm;  
					}else
					    echo  $UI__Rgst->nm;
				    ?>
			    </td>
				</tr>

                <?php 
                    if(($_REQUEST['id']>127349)) 
                    {
                ?>
                
                <tr class="item">
					<td><b>Deduction</b></td> 
					<td><b> &#8377; <?php // echo $tpaid;?></b></td>
				</tr>


                <?php } ?>

				<tr class="item colorText">
					<td><b>Amount Paid</b></td> 
					<td><b> &#8377; <?php echo $FResult->amountPaid;?></b></td>
				</tr>

				<tr class="item boldText">
					<td>UTR..</td> 
					<td><?php echo $acceptStats->UTR;?></td>
				</tr>

				
				<tr class="item last boldText colorText">
					<td>Status</td> 
					<td>
				    <?php 
				         
				    if(($FResult->bank=="Money Transfer")) 
					    {
					   
					    if($UI__TxnFailUsers->status==0)  
					    {
					   ?>
					     <span style="color:Blue;">Processing..</span>
					   <?php     
					      }
					   else 
				            echo  "Successful"; 
				        
		               } else
		                echo "Successful";
		            ?>
	            </td>
				</tr>  
				
				<tr class="item last boldText">
					<td>Date</td> 
					<td><?php echo $FResult->Tdate?></td>
				</tr>
				
				
				 
				<tr class="item last boldText">
				    <td>
				      <div class="withdrawaltimeline">
                        <h1>Withdrawal Timeline</h1>
                        <div class="history-tl-container">
                          <ul class="tl">
                            <li
                              class="tl-item activeSubmitted"
                              ng-repeat="item in retailer_history"
                            >
                              <div class="item-title">Submitted</div>
                              <div class="item-detail"><?php echo $FResult->Tdate?></div>
                            </li>
                            
                            
                            <?php 
                                if($acceptStats->rejStstus==1) {
                            ?>
                            <li  class=""> 
                            
                                   
                              <div class="item-title">Accepted Status</div>  
                              <div class="item-detail">
                                  Rejected
                              </div>  
                              </div>  
                            <?php }else { ?>
                            <li  class="tl-item <?php   if($accountSet==1) { if($acceptStats->acceptStats=='')    echo "activeAcceped"; else echo "activeSubmitted"; }else echo "activeSubmitted"; ?>"  ng-repeat="item in retailer_history"> 
                            
                                   
                              <div class="item-title">Accepted Status</div>  
                              <div class="item-detail">
                                 <?php 
                                 
                                    if($acceptStats->status==1)
                                    { 
                                        echo $acceptStats->acceptStats;    
                                    }else 
                                    {
                                 
                                    if($accountSet==1) 
                                    {
                                    if($acceptStats->acceptStats=='')  
                                        echo "Waiting to Accepted";
                                    else
                                        echo $acceptStats->acceptStats;
                                    }else
                                        echo $FResult->Tdate; 
                                    }
                                    
                                    ?>
                              </div> 
                            </li>
                            
                            <?php 
                            }
                                if($acceptStats->rejStstus==0) 
                                {
                                if($accountSet==1) 
                                {
                                
                                $MyDta =   date("Y-m-d", strtotime($FResult->Tdate)); 
                                $dt = strtotime($MyDta);
                                
                                // Add 1 month to the given date using strtotime() function
                                // and output the result in the format "Y-m-d"
                                 
                            ?>
                            <li class="tl-item <?php if($acceptStats->status==1) echo "activeSubmitted";?>" ng-repeat="item in retailer_history">
                              <div class="item-title">Credit to Bank Account</div>
                              <div class="item-detail">
                                <?php
                              
                                        if($acceptStats->status==1)
                                        {    
                                            echo "Paid on ".$acceptStats->paidDateTime;
                                        }else
                                        //echo "1st -".date("M", strtotime("+1 month", $dt))."-".date("Y"). " To 10th -".date("M", strtotime("+1 month", $dt))."-".date("Y");
                                        echo   "10 ".date("M Y");
                                    ?>
                                </div>
                            </li>
                            <?php }else { ?>
                            
                            <li class="tl-item <?php if($acceptStats->status==1) echo "activeSubmitted"; else if($UI__Rgst->pay2second==1) echo "activeSubmitted";?> " ng-repeat="item in retailer_history">
                              <div class="item-title">Credit to Bank Account</div>
                              <div class="item-detail"> 
                              
                                <?php 
                                     if( ($acceptStats->status==1))
                                        {    
                                            echo "Paid on ".$acceptStats->paidDateTime;
                                        }else if($UI__Rgst->pay2second==1) 
                                        {
                                            
                                        $stmt=$conn->prepare("select  status  from  UI__TxnFailUsersPay2 where cdId =:cdId ");   
                                        $stmt->bindValue(':cdId', $_REQUEST['id'] , PDO::PARAM_STR);  
                                        $stmt->execute(); 
                                        $UI__TxnFailUsersPay2 = $stmt->fetch(PDO::FETCH_OBJ); 
                                        
                                        if($UI__TxnFailUsersPay2->status==0)
                                            echo "Please wait Confirming..";
                                        else if($UI__TxnFailUsersPay2->status==1)
                                            echo "Paid on ".date("d-M-Y H:i"); 
                                        }
                                        else
                                            echo "Today Till 6:00 PM";
                                ?>
                              </div>
                            </li>
                            
                            <?php
                                    } 
                                }
                            ?>
                          </ul>
                        </div>
                      </div>
                      </td>
                </tr>
               

				<tr class="total">
					<td colspan="2">
					    <div class="printBtn">
					        <a class="btn" style="width:100%"  href="<?php echo  'https://www.dailypayservices.in/'.$_SERVER['REQUEST_URI'];?>"> 
							 <svg xmlns="http://www.w3.org/2000/svg" style="width: 11px;overflow: initial;" viewBox="0 0 384 512">
					            <!--!Font Awesome Free 6.6.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free Copyright 2024 Fonticons, Inc.--><path d="M105.1 202.6c7.7-21.8 20.2-42.3 37.8-59.8c62.5-62.5 163.8-62.5 226.3 0L386.3 160 352 160c-17.7 0-32 14.3-32 32s14.3 32 32 32l111.5 0c0 0 0 0 0 0l.4 0c17.7 0 32-14.3 32-32l0-112c0-17.7-14.3-32-32-32s-32 14.3-32 32l0 35.2L414.4 97.6c-87.5-87.5-229.3-87.5-316.8 0C73.2 122 55.6 150.7 44.8 181.4c-5.9 16.7 2.9 34.9 19.5 40.8s34.9-2.9 40.8-19.5zM39 289.3c-5 1.5-9.8 4.2-13.7 8.2c-4 4-6.7 8.8-8.1 14c-.3 1.2-.6 2.5-.8 3.8c-.3 1.7-.4 3.4-.4 5.1L16 432c0 17.7 14.3 32 32 32s32-14.3 32-32l0-35.1 17.6 17.5c0 0 0 0 0 0c87.5 87.4 229.3 87.4 316.7 0c24.4-24.4 42.1-53.1 52.9-83.8c5.9-16.7-2.9-34.9-19.5-40.8s-34.9 2.9-40.8 19.5c-7.7 21.8-20.2 42.3-37.8 59.8c-62.5 62.5-163.8 62.5-226.3 0l-.1-.1L125.6 352l34.4 0c17.7 0 32-14.3 32-32s-14.3-32-32-32L48.4 288c-1.6 0-3.2 .1-4.8 .3s-3.1 .5-4.6 1z"/>
					            </svg>
							 &nbsp;&nbsp; <B style="font-size:15px;">Refresh</B>
							</a>
					    </div>
					</td>
				</tr>
			</tbody></table>
			
			<a href="viewPdf.php?id=<?php echo $_REQUEST['id'];?>" id="go-back" class="PaySound " style="background-color: #747474;
                    border: none;
                    color: #fff;
                    padding: 5px 10px;
                    text-align: center;
                    text-decoration: none;
                    display: inline-block;
                    width:100%; 
                    border-radius:5px;
                    font-size: 15px;
                    margin: 4px 2px;
                    cursor: pointer;" >Download PDF</a>
                    
		</div>
       </div>
   </div>
     
</div>
 
<?php 
  include_once("../view/header-footer/footer.php");  
    unset($_SESSION['TpMsg']);