

@include('layouts.invoice')
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js"></script>
<div id="pagewrap">


	<div id="invoicevrajesh">
    <div class="invoice overflow-auto">
        <div style="min-width: 800px">
            <header>
                <div class="row">
                    <div class="col">
                        <a target="_blank" href="https://www.tannatechbiz.com/">
                            <img src="/dist/img/tannatechbiz.png" data-holder-rendered="true" />
                            </a>
                    </div>
					<div class="col company-details">
                        <h2 class="name">
                            <a target="_blank" href="https://www.tannatechbiz.com/">
                            Tanna TechBiz LLP
                            </a>
                        </h2>
                        <div>Vraj-Bhoomi, 22 New Jagnath Plot, Rajkot, Gujarat, 360 001</div>
                        <div>+919974300810</div>
                        <div>info@tannatechbiz.com</div>
                    </div>
                </div>
            </header>
			<main>
                <div class="row contacts">
                    <div class="col invoice-to">
                        <div class="text-gray-light"><h3>INVOICE TO:</h3></div>
                        <h2 class="to">{{ $company_details->name }}</h2>
                        <div class="address">0th Floor ,1004,Lokhandwala Township, Akurli Rd, Kandivli(e)</div>
                        <div class="email"><a href="mailto:{{ $company_details->email }}">{{ $company_details->email }}</a></div>
                    </div>
                    
                    <div class="col invoice-details">
                        <h1 class="invoice-id">Quotation:{{ $data->quotation_no }}</h1>
                        <div class="date"><h5>Date of Invoice: {{ $data->issue_date }}<h5></div>
                        
                    </div>
                </div>
                <div class="row contacts">
                <div class="col invoice-to">
                        <div class="text-gray-light"><h3>Billing Address:</h3></div>
                        <h4 class="to">{{ $company_details->name }}</h4>
                        <div class="address">0th Floor ,1004,Lokhandwala Township, Akurli Rd, Kandivli(e)</div>
                        <div class="email"><a href="mailto:john@example.com">john@example.com</a></div>
                    </div>
                    <div class="col invoice-details">
                        <div class="text-gray-light"><h3>Shipping Address:</h3></div>
                        <h4 class="to">{{ $company_details->name }}</h4>
                        <div class="address">796 Silver Harbour, TX 79273, US</div>
                        <div class="email"><a href="mailto:john@example.com">john@example.com</a></div>
                    </div>
                </div>

		
		
		
		
		<div style="clear:both"></div>
		
		
		<table id="items">
		
		  <tr>
			  <th>NO.</th>
		      <th>Item</th>
		      <th>Description</th>
		      <th>Unit Cost</th>
		      <th>Quantity</th>
			  <th>GST TYPE</th>
			  <th width="105px;">GST Amount</th>
		      <th>Price</th>
		  </tr>
          @foreach( $product_details as $value )
		  <tr >
			  <td></td>
		      <td class="item-name"><div class="delete-wpr"><span>{{ $value->unit_cost }}</span></div></td>
		      <td class="description"><span>{{ $value->description }}</span></td>
		      <td><span class="cost">₹{{ $value->unit_cost }}</span></td>
		      <td><span class="qty">{{ $value->quantity }}</span></td>
			  <td><span class="qty">{{ $value->i_gst }}</span></td>
			  <td><span class="qty">₹100</span></td>
		      <td><span class="price">₹650.00</span></td>
		  </tr>
          @endforeach
    	  <tr>
		      <td colspan="6" class="blank"> </td>
		      <td colspan="1" >Subtotal</td>
		      <td class="total-value"><div id="subtotal">₹875.00</div></td>
		  </tr>
		  <tr>
		      <td colspan="6" class="blank"> </td>
		      <td colspan="1" >GST</td>
		      <td class="total-value"><div id="total">₹875.00</div></td>
		  </tr>
		  <tr>
		      <td colspan="6" class="blank"> </td>
		      <td colspan="1" >Total</td>
		      <td class="total-value"><div id="total">₹875.00</div></td>
		  </tr>
		</table>
		
		<div id="terms">
		  <h5>Terms</h5>
		  <span>NET 30 Days. Finance Charge of 1.5% will be made on unpaid balances after 30 days.</span>
		</div>
        <button id="printInvoice">click</button>
	
	</div>
	
    <script>
$('#printInvoice').click(function(){
    console.log("hello");        
    Popup($('#invoice')[0].outerHTML);
            function Popup(data) 
            {
                window.print();
                return true;
            }
        });
</script>