@extends('layouts.app') @section('content')
Lead Details Add New Lead
@if(!empty($quote))
Customer Information
@if($quote->quote_stage == 3) @endif @php $quote_date = $quote->is_quoted != 1 ? date('Y-m-d') : date('Y-m-d', strtotime($quote->quote_date)); $due_date = is_null($quote->due_date) ? date('Y-m-d', strtotime('+7 days')) : date('Y-m-d', strtotime($quote->due_date)); @endphp {{ Form::open(['id'=>'dataForm'])}} {{ Form::hidden('customer_id', $quote->customer_id_fk, ['id'=>'customer_id']) }} {{ Form::hidden('lead_id', $quote->lead_id_fk, ['id'=>'customer_id']) }}
{{ Form::date('quote_date', $quote_date, array('class'=>'form-control'))}} @if ($errors->has('created_at')) {{ $errors->first('created_at') }} @endif
{{ Form::date('due_date', $due_date, array('class'=>'form-control'))}} @if ($errors->has('due_date')) {{ $errors->first('due_date') }} @endif
{{ Form::text('name', $lead->first_name.' '.$lead->last_name, ['class'=>'form-control', 'disabled'=>'disabled']) }}
{{ Form::text('company', $lead->company, ['class'=>'form-control']) }}
{{ Form::text('email', $lead->email, ['class'=>'form-control']) }} @if ($errors->has('email')) {{ $errors->first('email') }} @endif
{{ Form::text('mail_subject', $quote->subject, ['class'=>'form-control']) }} @if ($errors->has('mail_subject')) {{ $errors->first('mail_subject') }} @endif

{{ Form::close() }}
Quote Details:
Stage Amount Due Date Created at Created By Update Stage
INR {{$quote->amount}} {{date('d M, Y', strtotime($quote->due_date))}} {{date('d M, Y', strtotime($quote->created_at))}} {{$quote->user->name}} Download {{ Form::select('quote_stage',array(''=>'Please select')+$stages, $quote->quote_stage,['class'=>'form-control', 'id'=>'quote_stage']) }}
@php $total = 0 @endphp @if($cart) @foreach($cart as $id => $details) @endforeach @endif
Product Quantity Unit Price Tax Tax Amt. Subtotal
{{ $details['name'] }} {{ $details['quantity'] }} INR {{ $details['price'] }} {{ $details['tax'] }}% INR {{ $details['tax_amount'] }} INR {{ $details['cost'] }}
Total {{ $total }}
@else
SORRY! NO QUOTES FOUND!
@endif @if(!empty($deleted_quotes))

Previous Quotations

@foreach($deleted_quotes as $key => $old_cart)

Dated: {{date('d M, Y h:i A', strtotime($old_cart['order']->created_at))}}

@php $total = 0 @endphp @if($cart) @foreach($old_cart['cart'] as $id => $details) @endforeach @endif
Sr. Product Price Quantity Subtotal
{{$id+1}}. {{ $details['name'] }} INR {{ number_format($details['cost'] / $details['quantity'], 2) }} {{ $details['quantity'] }} INR {{ number_format($details['cost'], 2) }}
Total {{ number_format($total, 2) }}
@endforeach
@endif
@stop @section('scripting') @endsection