<?php 
  $header_file=APPPATH.'views/include/header.php';
  require($header_file);
  
  ?>
<style type="text/css">
  th {
    white-space: break-spaces;
    padding: 5px;
}
td{
  padding: 5px;
}
</style>
    <!-- BEGIN: Content-->
    <div class="app-content content">
      <div class="content-overlay"></div>
      <div class="content-wrapper" ng-app="anglist" ng-controller="anglistctlr">
        <div class="content-header row">
          <div class="content-header-left col-md-12 col-12 mb-2 breadcrumb-new">
            <h3 class="content-header-title mb-0 d-inline-block">GRN (Goods Received Note) List</h3>
            <div class="row breadcrumbs-top d-inline-block">
              <div class="breadcrumb-wrapper col-12">
                <ol class="breadcrumb">
                  <li class="breadcrumb-item"><a href="#">Home</a>
                  </li>
                  <li class="breadcrumb-item"><a href="#">Purchase Order</a>
                  </li>
                  <li class="breadcrumb-item active">GRN (Goods Received Note) List
                  </li>
                </ol>
              </div>
            </div>
          </div>
        
        </div>
        <div class="content-body"><!-- Zero configuration table -->
<section id="configuration">
    <div class="row justify-content-md-right">
       
            <div class="card"  >
                <div class="card-header">
                    <!--<h4 class="card-title">GRN (Goods Received Note) List</h4>-->
                    <a class="heading-elements-toggle"><i class="la la-ellipsis-v font-medium-3"></i></a>
                    <div class="heading-elements">
                        <ul class="list-inline mb-0">
                            <li><a data-action="collapse"><i class="ft-minus"></i></a></li>
                            <li><a data-action="reload"><i class="ft-rotate-cw"></i></a></li>
                            <li><a data-action="expand"><i class="ft-maximize"></i></a></li>
                            <li><a data-action="close"><i class="ft-x"></i></a></li>
                        </ul>
                    </div>
                </div>
                <div class="card-content collapse show">
                    <div class="card-body card-dashboard" >
                       
                        <div class="table-responsive" >
                            <table class="table table-striped table-bordered dataex-html5-export">
                                <thead>
                               
                                    <tr>
                                        <th>SL No</th>
                                        <th>Purchase No</th>
                                        <th>Purchase Date</th>
                                        <th>GRN No</th>
                                        <th>GRN Date</th>
                                        <th>Vendor</th>
                                        <th>Status</th>
                                        <th>View</th>
                                        <th>Atch</th>
                                    </tr>
                                </thead>
                                <tbody>
                                     <?php
									$count =1;
									foreach($grn_list as $grn)
									{
								?>
                                    <tr>
                                    	<td><?php echo $count; ?></td>
                                    	<td><?php echo $grn->purchase_no; ?></td>
										<td><?php echo $grn->purchase_date; ?></td>
										<td><?php echo $grn->grn_no; ?></td>
										<td><?php echo $grn->grn_date; ?></td>
										<td><?php echo $grn->vendor_name; ?></td>
									<?php
										if($grn->gnr_status == 'Pending') {
										?>
										<td class="pending_data"><span class="badge badge-danger"><?php echo $grn->gnr_status; ?></span></td>
										<?php
										} else if($grn->gnr_status == 'Holded') {
										?>
										<td class="hold_data"><span class="badge badge-danger"><?php echo $grn->gnr_status; ?></span></td>
										<?php
											} else {
										?>	
										<td class="success_data"><span class="badge badge-success"><?php echo $grn->gnr_status; ?></span></td>
										<?php
										}
									?>
									<td class="uk-text-nowrap">
										<a href="<?php echo site_url('Purchase/adm_grn_view/'. $grn->mid); ?>" id="view" name="view" class="btn btn-sm btn-info md-btn-success">View</a>
									</td>
									<td>
									    <?php
										if($grn->invoice_upload == '') {
										?>
										<img src="<?php echo base_url(); ?>app-assets/images/wrong.png"  class="img_main" />
										<?php } else { ?>
										<img src="<?php echo base_url(); ?>app-assets/images/right.png"  class="img_main" />
										<?php } ?>
									</td>	
								</tr>
                                    
                                   <?php
								  $count++;
								}
							  
							?>
                             </tbody>
                                </table>
                            </div>
                    </div>
                </div>
            </div>
        
    </div>
</section>
<!--/ Zero configuration table -->



<!--/ Language - Comma decimal place table -->

        </div>
      </div>
    </div>
    <!-- END: Content-->

   <?php //require('include/theme_customizer.php');?>
 <?php 
  $footer_file=APPPATH.'views/include/footer.php';
  require($footer_file);
  ?>
<script>
  $('.param_check').each(function() { $(this).on( {'click contextmenu': function() {
    //contextmenu
    var i = $(this).data('value');
    var anchor = $("a");
    var anchorTarget = $(this).parent().find('.parmetre').val();
    var submodid = $(this).parent().find('.submod_id').val();
    var link = $(this).attr('href');
    $(this).attr("href", link + submodid +'/'+anchorTarget);

    location.reload();
  }
  })
  })
</script>  
 </body>
  <!-- END: Body-->

<!-- Mirrored from pixinvent.com/modern-admin-clean-bootstrap-4-dashboard-html-template/html/ltr/vertical-modern-menu-template/form-layout-basic.html by HTTrack Website Copier/3.x [XR&CO'2014], Mon, 27 Apr 2020 09:38:02 GMT -->
</html>