@extends('layouts.dashboard') @section('title', 'Edit Proposal') @section('header-title', 'Edit Proposal') @section('content') @php $client = $proposal->client; $isSuperAdmin = auth()->user()->role?->slug === 'sp'; $group = fn(string $key) => $upgradations->get($key, collect()); $luxePackages = $group('luxe_package')->isNotEmpty() ? $group('luxe_package') : $group('luxury_package'); $selectedLuxePackageId = collect($proposal->selected_upgradations ?? []) ->first(fn($item) => abs((float) ($item['amount'] ?? 0) - (float) ($proposal->luxe_package_price ?? 0)) < 0.01)['id'] ?? null; @endphp
@if (session('success'))
{{ session('success') }}
@endif @if (session('error'))
{{ session('error') }}
@endif
@csrf @method('PUT')

{{ $proposal->proposal_number }}

Editing updates this proposal record.

Cancel

Client Details

@foreach (['billing' => 'Billing Address', 'site' => 'Site Address'] as $prefix => $title)

{{ $title }}

@if ($prefix === 'billing')
@endif
@endforeach

Product And Pricing

@foreach ([ 'original_price' => 'Original Price', 'requested_price' => 'Requested Price', 'installation_cost' => 'Installation', 'transport_cost' => 'Transportation', 'unloading_cost' => 'Unloading', 'gst_percentage' => 'GST %', 'discount_amount' => 'Discount Amount', 'delivery_amount' => 'Delivery Amount', ] as $field => $label)
@endforeach

Upgradations

@foreach ([ 'door_id' => ['Door', 'door'], 'color_id' => ['Color', 'color'], 'swing_id' => ['Swing', 'swing'], 'cop_id' => ['COP', 'cop'], 'extra_travel_height_id' => ['Extra Travel Height', 'extra_travel_height'], 'sos_id' => ['SOS', 'sos'], ] as $field => [$label, $groupType])
@endforeach

Warranty, Delivery And Terms

@foreach ([ 'warranty_type' => 'Warranty Type', 'warranty_years' => 'Warranty Years', 'amc_type' => 'AMC Type', 'amc_percentage' => 'AMC %', 'delivery_type' => 'Delivery Type', 'delivery_term' => 'Delivery Term', 'payment_terms_preset' => 'Payment Terms Preset', ] as $field => $label)
@endforeach
@foreach ([ 'payment_terms' => ['Payment Terms', 4], 'delivery_terms' => ['Delivery Terms', 4], 'installation_notes' => ['Installation Notes', 4], 'terms_and_conditions' => ['Terms & Conditions', 5], ] as $field => [$label, $rows])
@endforeach
Cancel
@endsection