<?php
	include('common/header.php');
?>
<style>
	.text-color-label{
		color: #212020;
		font-weight: bold;
	}
	.text-color-value{
		color: #30397d;
	}
	.table .table-bordered{
		border: 1px solid #212020 !important;
	}
</style>
		<div class="">
			<div class="col-xm-12">
				<div class="widget-box light-border">
					<div class="widget-header header-color-grey">
						<h4 class="smaller">
							Invoice
						</h4>
					</div>

					<div class="widget-body">
						<div class="widget-main">
						  <div class="row">
							<div class="col-sm-12">
							<form class="form-horizontal" name="add_employee" role="form">
								<!-- PAGE CONTENT BEGINS -->
								<div class="col-sm-12">
								<div class="col-sm-6">
									<div class="form-group">
										<label class="col-sm-5 control-label" for="form-field-1-1">Dealer Company <font color="red">*</font></label>

										<div class="col-sm-7">Gurudev Corporation</div>
									</div>

									<div class="space-4"></div>

									<div class="form-group">
										<label class="col-sm-5 control-label" for="form-field-1-1">Client <font color="red">*</font></label>

										<div class="col-sm-7">Ganraj PVT LTD</div>
									</div>

									<div class="space-4"></div>
									
									<div class="form-group">
										<label class="col-sm-5 control-label" for="form-field-1-1">Location <font color="red">*</font></label>

										<div class="col-sm-7">Mulund</div>
									</div>

									<div class="space-4"></div>
									
									
							</div>
							<div class="col-sm-6">
								
								<div class="form-group">
										<label class="col-sm-5 control-label" for="form-field-1-1">Agent <font color="red">*</font></label>

										<div class="col-sm-7">ABX</div>
									</div>

									<div class="space-4"></div>
								<div class="form-group">
									<label class="col-sm-5 control-label" for="form-field-1-1">Vessels <font color="red">*</font></label>

									<div class="col-sm-7">XYU</div>
								</div>
								<div class="space-4"></div>
								
							</div>
							</div>
						</form>	
							
						</div>
						</div>
					   </div>	
					</div>
				</div>
				<div class="space-4"></div>
				<div class="widget-box light-border">
					<div class="widget-header header-color-grey">
						<h4 class="smaller">
							Invoice Details
						</h4>
					</div>

					<div class="widget-body">
						<div class="widget-main">
						  <div class="row">
							<div class="col-sm-12">
							<form class="form-horizontal" role="form">
							<div class="col-sm-6">
								<!-- PAGE CONTENT BEGINS -->
									<div class="form-group">
										<label class="col-sm-5 control-label" for="form-field-2">Invoice No <font color="red">*</font></label>

										<div class="col-sm-7">201708220101</div>
									</div>
									<div class="space-4"></div>
									
									<div class="form-group">
										<label class="col-sm-5 control-label" for="form-field-2">Challan No <font color="red">*</font></label>

										<div class="col-sm-7">23456789</div>
									</div>
									<div class="space-4"></div>
									
									<div class="form-group">
										<label class="col-sm-5 control-label" for="form-field-2">Dispatched From <font color="red">*</font></label>

										<div class="col-sm-7">Thane</div>
									</div>

									<div class="space-4"></div>
									
									<div class="form-group">
										<label class="col-sm-5 control-label" for="form-field-2">Unloaded At <font color="red">*</font></label>

										<div class="col-sm-7">Mulund</div>
									</div>

									<div class="space-4"></div>
									<div class="form-group">
										<label class="col-sm-5 control-label" for="form-field-2">Credit Days <font color="red">*</font></label>

										<div class="col-sm-7">180 Days</div>
									</div>

									<div class="space-4"></div>
									
							</div>
							<div class="col-sm-6">
								<!-- PAGE CONTENT BEGINS -->
								
									<div class="form-group">
										<label class="col-sm-5 control-label" for="form-field-2">Invoice Date <font color="red">*</font></label>

										<div class="col-sm-7">24/07/2017</div>
									</div>
									
									<div class="space-4"></div>
									
									<div class="form-group">
										<label class="col-sm-5 control-label" for="form-field-2">Challan Date <font color="red">*</font></label>

										<div class="col-sm-7">23/07/2017</div>
									</div>
									
									<div class="space-4"></div>
							
									<div class="form-group">
										<label class="col-sm-5 control-label" for="form-field-2">Dispatched To <font color="red">*</font></label>

										<div class="col-sm-7">Mulund</div>
									</div>

									<div class="space-4"></div>
									
									<div class="form-group">
										<label class="col-sm-5 control-label" for="form-field-2">Truck No <font color="red">*</font></label>

										<div class="col-sm-7">MH-231232</div>
									</div>

									<div class="space-4"></div>
								
							</div>
						</form>	
							
						</div>
						</div>
					   </div>	
					</div>
				</div>
				<div class="space-4"></div>
				<div class="widget-box light-border">
					<div class="widget-header header-color-grey">
						<h4 class="smaller">
							Invoice Items Description
							
						</h4>
					</div>

					<div class="widget-body">
						<div class="widget-main">
						  <div class="row">
							<div class="col-sm-12 table-responsive">
							<table  cellspacing="0" width="100%" id="invoice_items" class="table table-bordered dataTable no-footer">
								<thead>		
									<tr>
										<th class="text-color-label">Description</th>
										<th class="text-color-label">Qty Pieces</th>
										<th class="text-color-label">Volumn CBM/CFT</th>
										<th class="text-color-label">Rate</th>
										<th class="text-color-label">Amount</th>
									</tr>	
								</thead>
								<tbody>	
									<tr id="tr_1">
										<td class="text-color-value">
											<div class="col-sm-7">Teak Log 1</div>
										</td>
										<td class="text-color-value">
											<div class="col-sm-7">1000</div>
										</td>
										<td class="text-color-value">
											<div class="col-sm-7">10</div>
										</td>
										<td class="text-color-value">
											<div class="col-sm-7">100.000</div>
										</td>
										<td class="text-color-value">
											<div class="col-sm-7">100000.000</div>
										</td>
									</tr>
									
									</tbody>
									
									<tfoot>
										<!--<tr>
											<td colspan="5" class="text-color-value text-right"><a href="javascript:void(0);" onclick="add_more();">Add More</a></td>
										</tr>
										<tr>
											<td colspan="4" class="text-right"><b>Total</b></td>
											<td class="text-color-value">
												<div class="col-sm-7">
													<?php	
														$total_amount_data=array('name'=>'total_amount',
																			  'id'=>'total_amount',
																			  'placeholder'=>'Total',
																			  'value'=> ''
																				);
														echo form_input($total_amount_data,'');
														echo form_error('total_amount');
													?>
												</div>
											</td>
										</tr>
										<tr>
											<td colspan="4" class="text-right"><b>Sub Total</b></td>
											<td class="text-color-value">
												<div class="col-sm-7">
													<?php	
														$total_amount_data=array('name'=>'total_amount',
																			  'id'=>'total_amount',
																			  'placeholder'=>'Sub Total',
																			  'value'=> ''
																				);
														echo form_input($total_amount_data,'');
														echo form_error('total_amount');
													?>
												</div>
											</td>
										</tr>-->
										<tr>
											<td colspan="4" class="text-right"><b>Grand Total</b></td>
											<td class="text-color-value">
												<div class="col-sm-7">100000.000</div>
											</td>
										</tr>
									</tfoot>
								</table>
							</div>
						</div>
					   </div>	
					</div>
				</div>
				</div>
			</div>
      	<!-- /.col -->
		</div>
		<div class="clearfix form-actions">
			<div class="col-md-offset-5 col-md-5">
				<button class="btn btn-info" type="button" onclick="javascript:history.go(-1);">
					Back
				</button>
				<button class="btn btn-info" type="button">
					Print
				</button>
			</div>
		</div>
		<div class="space-4"></div>
		<!-- /.page-row -->
        <!-- /.page-content --> 
      </div>
      <!-- /.main-content --> 
      
    </div>
    <!-- /#ace-settings-container --> 
  </div>
  
  <!-- /.main-container-inner --> 
 <script type="text/javascript">
$(document).ready(function() {
    $('form:first *:input[type!=hidden]:first').focus();
	get_cal();
});
function get_cal(){
	/* var total_sale_value=0.000;
	var total_sale_value_gst=0.000;
	//$('input[id^="invoice_item_id_"]').each(function(){
	$('input:checkbox').each(function(){
		if($(this).is(':checked')==true){
			total_sale_value = parseFloat(total_sale_value).toFixed(3) + (parseFloat($(this).parent().parent().find(".amt").html()).toFixed(3));
		}else{
			total_sale_value = parseFloat(total_sale_value).toFixed(3) + 0.000;
		}
	alert(total_sale_value);	
	});
	
	var cgst=parseFloat((total_sale_value * 9) / 100).toFixed(3);
	var sgst=parseFloat((total_sale_value * 9) / 100).toFixed(3);
	$(".cgst").html(cgst);
	$(".sgst").html(sgst);
	$(".igst").html('0.000');
	$(".total_sale_val").html(total_sale_value);
	$(".total_sale_gst_val").html(total_sale_value + cgst + sgst); */
}
</script>	

<?php
	include('common/footer.php');
?>