<!-- Service -->
       <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>
<script>
$(document).ready(function(){
    
      

        $("#cha tr").eq(1).remove();
        $("#cha tr").eq(0).remove();
           $("#cha tr").eq(2).remove();
            $("#cha tr").eq(2).remove();
            $("#cha tr").eq(2).remove();
     $('#cha > tbody > tr').last().remove();
        $('#cha > tbody > tr').last().remove();
         $("#cha tr").eq(0).addClass("headerate");
        $("#cha").each(function() {
  $("tr:gt(7)", this).addClass("hidden");
});
       

      
            
});
</script>
<script type="text/javascript">
    function CalculateEMI(){
      
var amount=$("#amount").val();

var rate=$("#rate").val();
rate=rate/100;

var period=$("#period").val();
var result=amount*rate*Math.pow((rate+1),period)/(Math.pow((1+rate),period)-1);
$("#result").val(Math.floor(result));



}


</script>
<style>
    .headerate{
        background-color: #018232; color: #fff;
    }
</style>

<?php
  $data=session('lng');
?>
<div class="row mix-block margin-bottom-40">
  <!-- TABS -->
  <div class="col-md-12 tab-style-1">
   

    <!-- Pricing -->
        <div class="col-md-6">
        
            <div class="pricing-head">
                   <h3> Today's Report</h3>
                   <div class="row" style="margin-top:30px;">
            <div class="col-md-12">
                <div>
                    <h5>Date: <?php echo e(date('F d, Y', strtotime($sss[0]->updated_at))); ?></h5>
                </div>
               <table class=" table" style="text-align: justify " >
                                                <tbody >
                                                    <tr>
                                                    <th class="col-md-6" scope="row" style="background-color: #b6b6b6" >शेयर पुंजी (Share Capital)</th>
                                                    <td><?php echo e($sss[0]->share_capital); ?></td>
                                                    </tr>
                                                    <tr>
                                                    <th class="col-md-6"style="background-color: #e9e9e9" scope="row">बचत (Saving)</th>
                                                    <td><p><?php echo e($sss[0]->saving,2); ?></p></td>
                                                    
                                                    </tr>
                                                    <tr>
                                                    <th class="col-md-6"style="background-color: #b6b6b6" scope="row">ऋण (Loan)</th>
                                                    <td><p><?php echo e($sss[0]->loan); ?></p></td>
                                                    </tr>
                                                    <tr>
                                                    <th class="col-md-6" style="background-color: #e9e9e9" scope="row">कुल सम्पति (Total Assets)</th>
                                                    <td><?php echo e($sss[0]->asset); ?></td>    
                                                    </tr>
                                                    <tr> 
                                                    <th class="col-md-6" style="background-color: #b6b6b6" scope="row">सदस्य संख्या (Total Member) </th>
                                                    <td><?php echo e($sss[0]->member_no); ?></td>
                                                    </tr>
                                                    <tr>
                                                    <th class="col-md-6" style="background-color: #e9e9e9" scope="row">जगेडा कोष (General Reserve) </th>
                                                    <td><?php echo e($sss[0]->backup_fund); ?></td>
                                                    </tr>
                                                    <tr>
                                                    <th class="col-md-6" style="background-color: #b6b6b6" scope="row">कारोबार गर्ने प्रथम सदस्य को नाम (First Transected Member)</th>
                                                    <td><?php echo e($sss[0]->first_member); ?></td>                               
                                                    </tr>
                                                    
                                                </tbody>
                                                
                                </table>
            
            </div>


             
          </div>


           
            
 
<table class="table" id="cha" >
<?php
// $homepage = file_get_contents('https://www.nrb.org.np/fxmexchangerate.php/');

// $str = substr( $homepage, strpos( $homepage, '<!--                These contents are dynamics-->'));
// $str=substr($str, 0,strpos($str, "Forex Graph"));
// $str= preg_replace("/<([a-z][a-z0-9]*)[^>]*?(\/?)>/i",'<$1$2>', $str);
// echo strip_tags($str,"<td><tr>");

?>
</table>
           
             
              <!-- END CAROUSEL -->
            </div>

           
        
        </div>
        <div class="col-md-6">
  <div class="pricing-head">
           <h3>EMI Calculator</h3>
          <div class="form-group" style="margin-top:30px;">
            <div class="row">
            <label class="col-md-6 control-label col-xs-12" for="title">Loan Amount(Rs.)</label>  
            <div class="col-md-6 col-xs-12">
              <input id="amount" name="amount" type="text" placeholder="amount in Rs." class="form-control input-md" required>
    
            </div>
          </div>
          </div>

          <div class="form-group">
            <div class="row">
            <label class="col-md-6 control-label col-xs-12" for="title">Interest Rate(%)</label>  
            <div class="col-md-6 col-xs-12">
              <input id="rate" name="rate" type="text" placeholder="Rate in %" class="form-control input-md" required>
    
            </div>
          </div>
        </div>

          <div class="form-group">
            <div class="row">
            <label class="col-md-6 control-label col-xs-12" for="title">Term (Months)</label>  
            <div class="col-md-6 col-xs-12">
              <input id="period" name="period" type="text" placeholder="time period" class="form-control input-md" required>
    
            </div>
          </div>
        </div>
          <div class="form-group">
            <div class="row">
            <div class="col-md-6 col-xs-12">
              <button type="submit" class="btn btn-primary" onclick="CalculateEMI()">Calculate</button>
            </div>
            <div class="col-md-6 col-xs-12">
              <input id="result" name="result" type="text" placeholder="" class="form-control input-md" >
    
            </div>

            
          </div>
        </div>
      </div>
        </div>

       
  </div>
  <!-- END TABS -->
</div>
<!-- Service -->
