<!-- ==================== MODAL ======================== -->

<div class="modal fade product-modal" tabindex="-1" role="dialog" aria-labelledby="myLargeModalLabel">
	<div class="modal-dialog modal-lg">
	    <div class="modal-content">
	 		<div class="content-heading">
	 			<h5>Add: Product 1</h5>
	 			<a class="close-btn" data-dismiss="modal" aria-label="Close">
	 				<i class="icon ion-ios-close-empty"></i>
	 			</a>
	 			<a class="add-btn">
	 				<i class="icon ion-ios-plus-empty"></i>
	 			</a>
	 		</div>
	 		<div class="product-number">
	 			<ul class="clearfix reset-list">
	 				<li>
	 					<a href="#" class="btn btn-success minus">
							<i class="icon ion-ios-minus-empty"></i>
	 					</a>
	 				</li>
	 				<li>
	 					<div class="item-number text-center">
	 						1
	 					</div>
	 				</li>
	 				<li>
	 					<a href="#" class="btn btn-success plus">
							<i class="icon ion-ios-plus-empty"></i>
	 					</a>
	 				</li>
	 			</ul>
	 		</div>
	 		<div class="quantity-price">
	 			<span class="price-amount">
	 				$20.00
	 			</span>
	 			<span class="label-text">Available quantity: </span><span class="success-text">20</span>
	 		</div>
	 		<div class="product-appearance">
	 			<h6 class="success-text">Size</h6>
	 			<ul class="reset-list clearfix product-list">
	 				<li><a href="#" class="btn-outline">S</a></li>
	 				<li><a href="#" class="btn-outline active">M</a></li>
	 				<li><a href="#" class="btn-outline">X</a></li>
	 				<li><a href="#" class="btn-outline">L</a></li>
	 				<li><a href="#" class="btn-outline">XL</a></li>
	 				<li><a href="#" class="btn-outline">XXL</a></li>
	 			</ul>
	 			<h6>Color</h6>
	 			<ul class="reset-list clearfix product-list">
	 				<li><a href="#" class="btn-outline">Red</a></li>
	 				<li><a href="#" class="btn-outline active">Green</a></li>
	 				<li><a href="#" class="btn-outline">Blue</a></li>
	 				<li><a href="#" class="btn-outline">White</a></li>
	 				<li><a href="#" class="btn-outline">Yellow</a></li>
	 				<li><a href="#" class="btn-outline">Orange</a></li>
	 				<li><a href="#" class="btn-outline">Violet</a></li>
	 				<li><a href="#" class="btn-outline">Purple</a></li>
	 				<li><a href="#" class="btn-outline">Brown</a></li>
	 				<li><a href="#" class="btn-outline">Black</a></li>
	 				<li><a href="#" class="btn-outline">Gold</a></li>
	 				<li><a href="#" class="btn-outline">Silver</a></li>
	 			</ul>
	 		</div>
	    </div>
	</div>
</div> <!-- Product modal -->

<div class="modal fade add-amount-modal" tabindex="-1" role="dialog" aria-labelledby="myLargeModalLabel">
	<div class="modal-dialog modal-lg">
	    <div class="modal-content">
	 		<div class="content-heading">
	 			<h5>Add Discount</h5>
	 			<a class="close-btn" data-dismiss="modal" aria-label="Close">
	 				<i class="icon ion-ios-close-empty"></i>
	 			</a>
	 			<a class="add-btn">
	 				<i class="icon ion-ios-plus-empty"></i>
	 			</a>
	 		</div>
	 		<div class="switch-btn">
	 			<div class="btn-group">
	 				<a href="#" class="btn btn-success percentage-tab">%</a>
	 				<a href="#" class="btn btn-default dollar-tab">$</a>
	 			</div>
	 		</div>
	 		<div class="result-btn">
	 			<div class="input-group">
	 				<input type="text" value="" id="numpadButton" class="form-control" id="result-text">
		 			<span class="input-group-btn">
						<button class="btn btn-default nmpd-target" id="numpadButton-btn" type="button" readonly="readonly" data-numpad="nmpd3"><i class="glyphicon glyphicon-th"></i></button>
					</span>
	 			</div>

	 		</div>
	 		<div class="numeric-btn">
				<div class="btn-group percentage-btn">
					<a href="#" id="five-percent" class="btn btn-default">5%</a>
					<a href="#" id="ten-percent" class="btn btn-default">10%</a>
					<a href="#" id="twenty-percent" class="btn btn-default">20%</a>
					<a href="#" id="thirty-percent" class="btn btn-default">30%</a>
					<a href="#" id="fifty-percent" class="btn btn-default">50%</a>
					<a href="#" id="clear-text" class="btn btn-default danger-text">Clear</a>
				</div>
	 		</div>
	    </div>
	</div>
</div> <!-- Add amount modal -->

<div class="modal fade cash-modal" tabindex="-1" role="dialog" aria-labelledby="myLargeModalLabel">
	<div class="modal-dialog modal-lg">
	    <div class="modal-content">
	 		<div class="content-heading">
	 			<h5>$151.80</h5>
	 			<a class="close-btn" data-dismiss="modal" aria-label="Close">
	 				<i class="icon ion-ios-close-empty"></i>
	 			</a>
	 		</div>
	 		<div class="switch-btn">
	 			<div class="btn-group">
	 				<a href="#" class="btn btn-success" id="cash-tab">Cash</a>
	 				<a href="#" class="btn btn-default" id="terminal-tab">External Terminal</a>
	 			</div>
	 		</div>
			<div class="switch-cash">
				<div class="balance-list">
					<ul class="clearfix">
						<li>$152.00</li>
						<li>$155.00</li>
						<li>$200.00</li>
					</ul>
				</div>
				<div class="result-box clearfix">
					<p class="result-text">$151.80</p>
					<div class="btn-tender">
						<a href="#" class="btn btn-lg btn-success">Tender</a>
					</div>

				</div>
			</div>
	 		<div class="switch-terminal">
	 			<div class="balance-list">
	 				<ul class="clearfix">
	 					<li>Master Card</li>
	 					<li>Visa</li>
	 					<li>Nets</li>
	 				</ul>
	 			</div>
	 			<div class="pay-container">
	 				<div class="input-group">
	 					<input type="text">
	 					<input type="text" placeholder="input approved code">
	 				</div>
	 				<div class="pay-btn">
	 					<input type="submit" value="Pay" class="btn btn-success btn-lg btn-block">
	 				</div>
	 			</div>
	 		</div>
	    </div>
	</div>
</div> <!-- cash modal -->

<div class="modal fade payment-modal" tabindex="-1" role="dialog" aria-labelledby="myLargeModalLabel">
	<div class="modal-dialog modal-lg">
	    <div class="modal-content">
	 		<div class="content-heading">
	 			<h5>$24.00 charged of $200.00</h5>
	 			<a class="close-btn" data-dismiss="modal" aria-label="Close">
	 				<i class="icon ion-ios-close-empty"></i>
	 			</a>
	 		</div>
	 		<div class="receipts-container">
	 			<p class="label-text">Do you want to send the receipts?</p>
	 			<form action="#">
	 				<div class="form-group">
	 					<input type="text" placeholder="Email Receipts" class="form-control">
	 				</div>

	 				<input type="submit" class="btn btn-success btn-block">
	 			</form>
	 		</div>
	    </div>
	</div>
</div> <!-- payment modal -->

<div class="modal fade no-conn-modal" tabindex="-1" role="dialog" aria-labelledby="myLargeModalLabel">
	<div class="modal-dialog modal-lg">
	    <div class="modal-content">
	 		<p>There is no internet connection.</p>
	 		<p>Email will be sent later.</p>
	 		<div class="ok-btn">
	 			<a href="#" data-dismiss="modal" aria-label="Close">OK</a>
	 		</div>
	    </div>
	</div>
</div> <!-- no connection modal -->

<div class="modal fade yes-no-modal" tabindex="-1" role="dialog" aria-labelledby="myLargeModalLabel">
	<div class="modal-dialog modal-lg">
	    <div class="modal-content">
	 		<p>Are you sure you want to cancel payment proccess?</p>
	 		<div class="yes-no-btn">
	 			<a href="#" class="yes-btn">Yes</a>
	 			<a href="#" class="no-btn" data-dismiss="modal" aria-label="Close">No</a>
	 		</div>
	    </div>
	</div>
</div> <!-- no connection modal -->

<div class="modal fade item-list-modal" tabindex="-1" role="dialog" aria-labelledby="myLargeModalLabel" id="edit-sidebar-item">
	<div class="modal-dialog modal-lg">
	    <div class="modal-content">
	 		<div class="content-heading">
	 			<h5>$24.00 charged of $200.00</h5>
	 			<a class="close-btn" data-dismiss="modal" aria-label="Close">
	 				<i class="icon ion-ios-close-empty"></i>
	 			</a>
	 		</div>
	 		<div class="item-container">
	 			<div class="item-unit">
		 			<ul class="clearfix reset-list">
		 				<li>
		 					<a href="#" class="btn btn-success minus">
								<i class="icon ion-ios-minus-empty"></i>
		 					</a>
		 				</li>
		 				<li>
		 					<div class="item-number text-center">
		 						<div class="input-group">
									{{ Form::text('item-number', '', array('class' => 'form-control', 'id' => 'item-number')) }}
									<span class="input-group-btn">
										<a class="btn btn-default nmpd-target" id="item-number-btn" type="button" readonly="readonly" data-numpad="nmpd3"><i class="glyphicon glyphicon-th"></i></a>
									</span>
								</div>
		 					</div>

		 					<input type="hidden" name="product-id" id="product-id">
		 					<input type="hidden" name="order-id" id="order-id">
		 				</li>
		 				<li>
		 					<a href="#" class="btn btn-success plus">
								<i class="icon ion-ios-plus-empty"></i>
		 					</a>
		 				</li>
		 			</ul>
		 		</div>
				{{ Form::open(array('url' => 'sale','class'=>'edit-sidebar-item-form')) }}
					<div class="row">
						<div class="col-sm-2">
							{{ Form::label('item-price', Trans('products.price')) }}
						</div>
						<div class="col-sm-10">
							<div class="input-group">
								{{ Form::text('item-price', '', array('class' => 'form-control', 'id' => 'item-price')) }}
								<span class="input-group-btn">
									<button class="btn btn-default nmpd-target" id="item-price-btn" type="button" readonly="readonly" data-numpad="nmpd3"><i class="glyphicon glyphicon-th"></i></button>
								</span>
							</div>

						</div>
					</div>
					<div class="row">
						<div class="col-sm-2">
							{{ Form::label('item-discount', Trans('products.discount')) }}
						</div>
						<div class="col-sm-10">
							<div class="input-group">
								{{ Form::text('item-discount', '', array('class' => 'form-control', 'id' => 'item-discount')) }}
								<span class="input-group-btn">
									<button class="btn btn-default nmpd-target" id="item-discount-btn" type="button" readonly="readonly" data-numpad="nmpd3"><i class="glyphicon glyphicon-th"></i></button>
								</span>
							</div>
						</div>
					</div>
					<div class="row btn-foot">
						<input type="submit" name="submit" class="hidden">
						<div class="col-sm-6">
							{{ HTML::link('#', Trans('sale.save'), array('class' => 'btn btn-success btn-block save-item')) }}
						</div>
						<div class="col-sm-6">
							{{ HTML::link('#', Trans('sale.delete'), array('class' => 'btn btn-danger btn-block remove-item')) }}
						</div>
					</div>
				{{ Form::close() }}
	 		</div>
	    </div>
	</div>
</div> <!-- item list modal -->

<div class="modal fade currency-modal" role="dialog" aria-labelledby="myLargeModalLabel">
	<div class="modal-dialog modal-lg">
	    <div class="modal-content">
	    	<div class="modal-bg">
	    		<a class="close-btn" data-dismiss="modal" aria-label="Close">
	    			<i class="icon ion-ios-close-empty"></i>
	    		</a>
	    	</div>
 			<div class="content-heading">
	 			<div class="row price-title">
	 				<div class="col-sm-6 text-center">
	 					<span class="price-title-dollar"></span>
	 				</div>
	 				<div class="col-sm-6 text-center">
	 					<span class="price-title-riel"></span>
	 				</div>
	 			</div>
	 		</div>
	 		{{ Form::open(array('url' => 'checkout', 'autocomplete' => "off")) }}
		 		<div class="row currency-form-wrapper">
					<div class="form-group select-customer-wrapper">
			 			<div class="col-sm-3">
			 				<label for="select-customer text-right">{{ Trans('sale.choose_customer')}}</label>
				 		</div>
				 		<div class="col-sm-9">
				 			<select name="select-customer" id="select-customer" class="customer" data-customer-list-url="{{route('customersList')}}">
				 				<?php
										if(isset($customer)){
											foreach ($customer as $key => $value) {
												echo '<option value="'.$key.'" selected="selected">'.$value.'</option>';
											}
											
										}
									?>
				 			</select>
				 		</div>
					</div>
			 		<div class="col-sm-12">
				 		<div class="currency-container">
				 			<div>
			 					<div class="row">
			 						<div class="col-sm-6">
			 							<div class="input-dollar">
			 							   {{ Form::label('input-dollar', Trans('sale.'.Helper::getConfig('invoice_currency'))) }}
			 							   <div class="input-group input-group-lg">
			 							   	{{ Form::number('input-dollar', '0', array('placeholder' => '0', 'id' => 'input-dollar', 'class'=> 'form-control','step'  => "any",'min'   => '0')) }}
			 							   	<span class="input-group-btn">
														<button class="btn btn-default nmpd-target" id="usd-btn" type="button" readonly="readonly" data-numpad="nmpd3"><i class="glyphicon glyphicon-th"></i></button>
												</span>
			 							   </div>
			 							</div>
			 						</div>
			 						<div class="col-sm-6">
			 							<div class="form-group">
			 							   {{ Form::label('input-riel', Trans('sale.'.Helper::getConfig('second_invoice_currency'))) }}
			 							   <div class="input-group input-group-lg">
				 							   {{ Form::number('input-riel', '0', array('id' => 'input-riel', 'placeholder' => '0', 'class'=> 'form-control')) }}
				 							   	<span class="input-group-btn">
														<button class="btn btn-default nmpd-target" id="riel-btn" type="button" readonly="readonly" data-numpad="nmpd3"><i class="glyphicon glyphicon-th"></i></button>
												</span>
			 							   </div>
			 							</div>
			 						</div>
			 						<div class="col-sm-12">
			 							<div class="recieved-total-wrap">
			 							    <p>{{ Trans('sale.change_money')}}</p>
			 							    <div class="input-group-lg input-group">
			 							    	<input id="received-total" type="text" class="form-control" disabled>
			 							    </div>
			 							</div>
			 						</div>
			 						<div class="print-switch">
				 						<div class="col-sm-2 col-sm-offset-7 ">
			 								<div class="switch-wrapper">
			 									{{Form::checkbox('print-invoice',null, true, ['class' => 'switch', 'id' => 'print-invoice'])}}
			 									<label for="print-invoice"></label>
			 								</div>
				 						</div>
				 						<div class="col-sm-3 switch-label">
				 							<label for="">{{ Trans('sale.print_invoice')}}</label>
				 						</div>
			 						</div>
			 					</div>
			 					<hr>
			 					<div class="row">
			 						<div class="col-sm-4">
			 							{{ Form::submit(Trans('sale.checkout'), array('class' => 'btn btn-success btn-lg btn-block', 'id' => 'btn-submit', 'name' => 'checkout')) }}
			 						</div>
			 						<div class="col-sm-4">
			 							{{ Form::submit(Trans('sale.save'), array('class' => 'btn btn-success btn-lg btn-block save-invoice', 'id' => 'btn-submit', 'name' => 'save')) }}
			 						</div>
			 						<div class="col-sm-4">
			 							<a class="btn btn-warning btn-lg btn-block" href="{{Route('discard')}}">
							    			{{ Trans('sale.discard')}}
							    		</a>
			 						</div>
			 					</div>
				 			</div>
				 		</div>
			 		</div>
		 		</div>
	 		{{ Form::close() }}
	    </div>
	</div>
</div>

<!--Customer Modal-->
<div class="modal fade" id="customerModal" tabindex="-1" role="dialog">
  <div class="modal-dialog modal-md" id="dialog" role="document" style="padding-top:20px;">
    <div class="modal-content">
      <div class="modal-header">
        <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
        <h4 class="modal-title">{{ trans('customers.add_new') }}</h4>
      </div>
      {{ Form::open([ 'method' => 'post', 'action' => 'sale.new_customer', 'id' => 'form-add-customer']) }}
      <div class="modal-body">
        <div class="row">
        	<div class="col-md-6">
        		<div class="form-group{{ $errors->has('first_name') ? ' has-error' : '' }}">
        		    {{ Form::label('first_name', trans('customers.first_name')) }}
        		    {{ Form::text('first_name', null, ['class' => 'form-control', 'placeholder' => trans('customers.first_name'), 'id' => "first_name"]) }}
        		    <small class="text-danger">{{ $errors->first('first_name') }}</small>
        		</div>
        	</div>
        	<div class="col-md-6">
        		<div class="form-group{{ $errors->has('last_name') ? ' has-error' : '' }}">
        		    {{ Form::label('last_name', trans('customers.last_name')) }}
        		    {{ Form::text('last_name', null, ['class' => 'form-control', 'required' => 'required', 'placeholder' => trans('customers.last_name')]) }}
        		    <small class="text-danger">{{ $errors->first('last_name') }}</small>
        		</div>
        	</div>
        </div>
        <div class="row">
        	<div class="col-md-12">
        		<div class="form-group{{ $errors->has('tel') ? ' has-error' : '' }}">
        		    {{ Form::label('tel', trans('customers.tel')) }}
        		    {{ Form::text('tel', null, ['class' => 'form-control', 'placeholder' => trans('customers.tel')]) }}
        		    <small class="text-danger">{{ $errors->first('tel') }}</small>
        		</div>
        	</div>
        	<div class="col-md-12">
        		<div class="form-group{{ $errors->has('first_name') ? ' has-error' : '' }}">
        		    {{ Form::label('address', trans('customers.address')) }}
        		    {{ Form::textarea('address', null, ['class' => 'form-control', 'rows' => '3', 'placeholder' => trans('customers.address')]) }}
        		    <small class="text-danger">{{ $errors->first('address') }}</small>
        		</div>
        	</div>
        </div>
      </div>
      <div class="modal-footer">
        <button type="button" class="btn btn-default" data-dismiss="modal">{{ trans('dashboard.crud.cancel') }}</button>
        <button type="submit" class="btn btn-primary">{{ trans('dashboard.crud.add') }}</button>
      </div>
      {{ Form::close() }}
    </div><!-- /.modal-content -->
  </div><!-- /.modal-dialog -->
</div><!-- /.modal -->
<div class="modal fade" id="orderProductModal" tabindex="-1" role="dialog">
  <div class="modal-dialog modal-md" id="dialog" role="document" style="padding-top:20px;">
    <div class="modal-content">
      <div class="modal-header">
        <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
        <h4 class="modal-title order-title">{{ trans('Order New Product') }} <span class="product_order_sku"></span></h4>
      </div>
      <div class="modal-body">   
      	<div class="row barcode-sku">
      		<div class="col-md-12">
      			{{ Form::open(array('method'=>'POST', 'class'=>'submit_sku_f4', 'autocomplete'=> 'off')) }}
      				<div class="form-group">
      					{{ Form::label('sku', trans('products.sku')) }}
								{{ Form::text('barcode', '', array('placeholder'=>Trans('products.sku'),'class'=>'form-control product_sku', 'data-url' => route("sale.newOrderProduct") )) }}
								<input type="submit" name="submit" class="hidden">      					
      				</div>
						{{ Form::close() }}
      		</div>
      	</div>     	
      	{{ Form::open(['route' => "checkPriceIn", 'id' => 'form-add-new-order']) }}
        <div class="row">
        	<div class="col-md-12 form-new-order">
        		{{ Form::hidden('product_id', null, ['class' => "p_id"]) }}
        		{{ Form::hidden("sku", null, ['class' => 'p_sku']) }}
        		<div class="form-group">
        		    {{ Form::label('price', trans('products.price')) }}
        		    {{ Form::number('price', null, [
        		    		'class' => 'form-control p_price',
        		    		'placeholder' => trans('products.price'),
        		    		'step'	=>	"any",
        		    		'required'	=>	"required"
        		    ]) }}
        		</div>
        		<div class="form-group">
        		    {{ Form::label('amount', trans('products.amount')) }}
        		    {{ Form::number('amount', null, [
        		    		'class' => 'form-control p_amount',
        		    		'placeholder' => trans('products.amount'),
        		    		'required'	=>	"required"
        		    ]) }}
        		</div>
        	</div>
        </div>
      </div>
      <div class="modal-footer">
        <button type="button" class="btn btn-default" data-dismiss="modal" tabindex="-1">{{ trans('dashboard.crud.cancel') }}</button>
        <button type="submit" id="btn-confirm-order" class="btn btn-primary">{{ trans('dashboard.crud.add') }}</button>
      </div>
      {{ Form::close() }}
    </div><!-- /.modal-content -->
  </div><!-- /.modal-dialog -->
