<?php 
	$header_file=APPPATH.'views/include/header.php';
	require($header_file);
	$sidenav_file=APPPATH.'views/include/sidenav.php';
	require($sidenav_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">Raw Material </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="#">Raw Material</a>
                  </li>
                  <li class="breadcrumb-item active">Raw Material Updation
                  </li>
                </ol>
              </div>
            </div>
          </div>
          
        </div>
        <div class="content-body"><!-- Basic form layout section start -->
<section id="basic-form-layouts">

	<div class="row justify-content-md-center">
		<div class="col-md-12">
			<div class="card">
				<div class="card-header">
					<h4 class="card-title" id="basic-layout-form-center">Raw Material Updation</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">

						 <?php 	foreach($rawItem as $key => $data) ?>

						<form class="form" autocomplete="off" action="<?php echo site_url('Master/updateCRawMaterial');?>" method="post" enctype="multipart/form-data">
							<div class="row justify-content-md-center">
								
								<div class="col-md-4">
									<div class="form-body">
										<div class="form-group">
											<label>Product Name</label>
											<input type="text" name="product_name" class="form-control product_name pname" id="product_name" value="<?php echo $data->item_name ?>"   readonly/>
											<input type="hidden" name="item_id" class="form-control " id="item_id" value="<?php echo $data->item_id;?>"  
											<input type="hidden" name="itm_id" class="form-control " id="itm_id" value="<?php echo $data->itm_id;?>"   />
											<span id="err" class="redText" style="display:none;">Product Already in Use</span>
										<!--	<input type="hidden" class="sub_mod_id" name="sub_mod_id" id="submod_id" value="<?php //echo $submod_id; ?>" >-->
										</div>
									</div>
								</div>
								<div class="col-md-2">
									<div class="form-body">
										<div class="form-group">
											<label>UOM</label>
											<input type="text" name="unit_of_measure" class="form-control unit_of" id="unit_of_measure" value="<?php echo $data->uom;?>" readonly placeholder="UOM" />
											
											<?php $cur_date = date("Y-m-d"); ?>
											
											
										</div>
									</div>
								</div>
								<div class="col-md-2">
									<div class="form-body">
										<div class="form-group">
											<label>Price</label>
											<input type="text" name="price" class="form-control" id="price" value="<?php echo $data->item_price ;?>"  />
										</div>
									</div>
								</div>
								<div class="col-md-2">
									<div class="form-body">
										<div class="form-group">
											<label>Tax(%)</label>
											<input type="text" name="tax" class="form-control" id="tax" value="<?php echo $data->item_tax ;?>"  />
										</div>
									</div>
								</div>
							</div>
							<div class="form-actions text-center">
								<button type="reset" class="btn btn-warning mr-1">
									<i class="ft-x"></i> Cancel
								</button>
								<button type="submit" class="btn btn-primary">
									<i class="la la-check-square-o"></i> Save
								</button>
							</div>
						</form>	

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

</section>
<!-- // Basic form layout section end -->
        </div>
      </div>
    </div>
    <?php //require('include/theme_customizer.php');?>

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

<script type="text/javascript">
	$(function () {
		$('#branch').multiselect({
			includeSelectAllOption: true
		});
	});
	
	$(function () {
		$('#sale_br_id').multiselect({
			includeSelectAllOption: true
		});
	});
	$(function () {
		$('#santhe_br_id').multiselect({
			includeSelectAllOption: true
		});
	});
	
</script>
</body>
</html>