<?php 
	$header_file=APPPATH.'views/include/header.php';
	require($header_file);
	
	?>

    <!-- BEGIN: Content-->
    <div class="app-content content">
      <div class="content-overlay"></div>
      <div class="content-wrapper">
        <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">Product Mapping</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="#">Product Mapping</a>
                  </li>
                  <li class="breadcrumb-item active">Mapping List
                  </li>
                </ol>
              </div>
            </div>
          </div>
        
        </div>
        <div class="content-body"><!-- Zero configuration table -->
<section id="configuration">
    <div class="row">
        <div class="col-12">
            <div class="card">
                
                <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>Layering Name</th>
										<th>Product Name</th>
                                    </tr>
                                </thead>
                                <tbody>
								 <?php
									$count =1;
									foreach($prMapping as $record)
								{
								?>
                                    <tr>
                                        <td><?php echo $count;?></td>
                                        <td><?php echo $record['rname']; ?></td>
										<td><?php //echo $record['map_recipe_no'];
										$branch_id = $_SESSION['branch_id'];
										$map_recipe_no=$record['map_recipe_no'];
										$q1 = $this->db->query("select rname from recipe where recipe_no='$map_recipe_no' and branch_id='$branch_id'");
										$vres = $q1->result();
										foreach($vres as $vrow){
										echo $vrow->rname;
										}
										?>
										
										</td>
										
                                    </tr>
                                    
                                   <?php
								  $count++;
								}
							  
							?>
                                </tbody>
                              
                            </table>
                        </div>
                    </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>
	$(document).on("click",".item_status",function(){
		var itm_id=$(this).attr('itm-id');
		var item_status=$(this).attr('item-status');
			$.ajax({
			type: "POST",
			dataType:'json',
			data : { itm_id : itm_id, item_status : item_status},
			url: "<?php echo base_url();?>index.php/Master/change_item_status",
			success: function(dataz) { 
				var data = $.trim(dataz);
				
				setInterval(function(){
						window.location.reload(true);
					}, 400);
			}
		});
	});
</script>
<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>