@extends('layouts.usermain') @section('main-container')
📋 Table 1.1 - Farmer Profile
@if($baseline->upload_respondent_photo) @endif
Application Number {{ $baseline->application_code ?? 'N/A' }} Respondent Photo
Name of TSF Operational Area/Unit {{ $baseline->unit->name ?? 'N/A' }}
State Name {{ $baseline->state->name ?? 'N/A' }}
Date of Survey {{ \Carbon\Carbon::parse($baseline->date_of_survey)->format('d-m-Y') ?? 'N/A' }}
Year of Baseline Survey {{ $baseline->financialYear->name ?? 'N/A' }}
District Name {{ $baseline->district->name ?? 'N/A' }}
Block Name {{ $baseline->block->name ?? 'N/A' }}
Panchayat Name {{ $baseline->panchayat->name ?? 'N/A' }}
Village Name {{ $baseline->village->name ?? 'N/A' }}
WHS (Project Type) {{ $baseline->projectType->name ?? 'N/A' }}
Name of Respondent {{ $baseline->name_of_respondent ?? 'N/A' }}
Mobile Number {{ $baseline->mobile_number ?? 'N/A' }}
Alternate Mobile Number {{ $baseline->alternet_mobile_number ?? 'N/A' }}
Table 1.2 - Family Members
@if($baseline->households->count())
@foreach ($baseline->households as $member) @endforeach
Name Age Gender Category Education Level
{{ $member->name ?? 'N/A' }} {{ $member->age ?? 'N/A' }} {{ ucfirst($member->gender) ?? 'N/A' }} {{ $member->category ?? 'N/A' }} {{ $member->education_level ?? 'N/A' }}
@else

No family members recorded.

@endif
{{-- Table 1.3: Land Holding Information --}}
Table 1.3 - Land Holding Information
@if($baseline->lands && $baseline->lands->count()) @foreach($baseline->lands as $land) @endforeach
Plot/Khata Type of Land Total Area (Acre) Irrigated Area (Acre) Non-Irrigated Area (Acre) Sources of Irrigation
{{ $land->plot_khata }} {{ $land->land_type }} {{ $land->area }} {{ $land->irrigated_area }} {{ $land->non_irrigated_area }} @if(is_array($land->irrigation_sources)) {{ implode(', ', $land->irrigation_sources) }} @else {{ $land->irrigation_sources }} @endif
@else

No land information available.

@endif
{{-- Repeat similar blocks for livestocks, waterUserGroups, etc. --}}
Table 1.4 - Water Harvesting Structures Planning
@foreach ($baseline->waterHarvestingStructuresPlanning as $waterHarvesting) @endforeach
Type of Structure Length (m) Width (m) Depth/Height (m) Latitude Longitude Geotagged Pre-Photos
{{ $waterHarvesting->projectType->name ?? '-' }} {{ $waterHarvesting->length ?? 'N/A' }} {{ $waterHarvesting->width ?? 'N/A' }} {{ $waterHarvesting->depth_or_height ?? 'N/A' }} {{ $waterHarvesting->latitude ?? 'N/A' }} {{ $waterHarvesting->longitude ?? 'N/A' }} @if ($waterHarvesting->geotagged_file) View Photo @else N/A @endif
Uploaded Documents
@if($baseline->documentUpload->beneficiary_agreement) View PDF @else

Not Uploaded

@endif
@if($baseline->documentUpload->khata_document) View PDF @else

Not Uploaded

@endif
@if($baseline->documentUpload->other_document) View PDF @else

Not Uploaded

@endif
Table 1.5: WHS Technical Feasibility
Catchment Area (ha) Land Slope Geological Location Hydrological Location Distance from Drainage (m) LULC
{{ $baseline->TechnicalFeasibility->catchment_area ?? 'N/A' }} {{ $baseline->TechnicalFeasibility->land_slope ?? 'N/A' }} {{ $baseline->TechnicalFeasibility->geological_location ?? 'N/A' }} {{ $baseline->TechnicalFeasibility->hydrological_location ?? 'N/A' }} {{ $baseline->TechnicalFeasibility->distance_from_drainage_line ?? 'N/A' }} {{ $baseline->TechnicalFeasibility->lulc ?? 'N/A' }}
Total Score: {{ $baseline->TechnicalFeasibility->technical_feasibility_score ?? '0.00' }}
Table 1.6: Water User Group
@php $totalLand = 0; @endphp @foreach ($baseline->waterUserGroups as $index => $group) @php $landArea = $group->land_comment ?? 0; $totalLand += $landArea; @endphp @endforeach
S.No. Name of Beneficiary Category Plot/Khata No. Land Area (Acre) Potential Irrigation (Acre)
{{ $index + 1 }} {{ \Illuminate\Support\Str::title($group->name_of_beneficiary ?? 'N/A') }} {{ $group->category ?? 'N/A' }} {{ $group->plot_khata_no ?? 'N/A' }} {{ number_format($landArea, 2) }} {{ number_format($group->potential_irrigation ?? 0, 2) }}
Total Land (Acre) {{ number_format($totalLand, 2) }}

Table 1.7: Crop Details

@php $totalIncome = 0; @endphp @foreach ($baseline->croppings as $index => $crop) @php $totalIncome += $crop->total_income ?? 0; @endphp @endforeach
S.No. Season Category Crop Area (Acre) Production (Qtl) Productivity Market Rate (₹/Qtl) Total Income (₹) Cost (₹) Profit (₹)
{{ $index + 1 }} {{ $crop->season->name ?? 'N/A' }} {{ $crop->category->name ?? 'N/A' }} {{ $crop->crop->name ?? 'N/A' }} {{ $crop->cultivation ?? 'N/A' }} {{ $crop->production ?? 'N/A' }} {{ $crop->productivity ?? 'N/A' }} {{ $crop->market_rate ?? 'N/A' }} {{ number_format($crop->total_income ?? 0, 2) }} {{ number_format($crop->cost ?? 0, 2) }} {{ number_format($crop->profit ?? 0, 2) }}
Total Income (₹) {{ number_format($totalIncome, 2) }}

Table 1.8: Livestock Details

@php $totalNetIncome = 0; @endphp @foreach($baseline->livestocks as $index => $livestock) @php $netIncome = ($livestock->total_income ?? 0) - ($livestock->cost_rearing ?? 0); $totalNetIncome += $netIncome; @endphp @endforeach
S.No. Name of Livestock Number Purpose of Rearing Total Income (₹) Cost of Rearing (₹) Net Income (₹)
{{ $index + 1 }} {{ $livestock->name ?? 'N/A' }} {{ $livestock->number ?? 'N/A' }} {{ $livestock->purpose_rearing ?? 'N/A' }} {{ number_format($livestock->total_income ?? 0, 2) }} {{ number_format($livestock->cost_rearing ?? 0, 2) }} {{ number_format($netIncome, 2) }}
Total Net Income (₹) {{ number_format($totalNetIncome, 2) }}

Table 1.9: Other Allied Sector Report

@foreach($baseline->alliedsectors as $index => $sector) @endforeach
S.No. Allied Sector Annual Production Unit of Measurement Market Rate (₹) Total Income (₹) Annual Expenditure (₹) Net Income (₹)
{{ $index + 1 }} {{ $sector->sector_name ?? 'N/A' }} {{ $sector->annual_production ?? 'N/A' }} {{ $sector->unit_of_measurement ?? 'N/A' }} {{ number_format($sector->market_rate ?? 0, 2) }} {{ number_format($sector->total_income ?? 0, 2) }} {{ number_format($sector->annual_expenditure ?? 0, 2) }} {{ number_format($sector->net_income ?? 0, 2) }}
Total Net Income (₹) {{ number_format($baseline->alliedsectors->sum('net_income'), 2) }}
Table 1.9 - Micro Enterprises / Small Business
@if($baseline->microEnterprises->count())
@foreach ($baseline->microEnterprises as $enterprise) @endforeach
Business Name Entrepreneur Name Persons Employed Total Income Annual Expenditure Net Income Registration Status
{{ $enterprise->business_name ?? 'N/A' }} {{ $enterprise->entrepreneur_name ?? 'N/A' }} {{ $enterprise->persons_employed ?? 'N/A' }} {{ $enterprise->total_income ?? 'N/A' }} {{ $enterprise->annual_expenditure ?? 'N/A' }} {{ $enterprise->net_income ?? 'N/A' }} {{ $enterprise->registration_status ?? 'N/A' }}
Total Net Income (₹) {{ $baseline-> crop_income_total ?? 'N/A' }}
@else
No data available. This household is not engaged in any Micro Enterprises or Small Business.
@endif

Table 1.10: Daily Wage Labor

@if($baseline->dailyWageLabors->count())
@php $totalNetIncome = 0; @endphp @foreach ($baseline->dailyWageLabors as $labor) @php $totalNetIncome += $labor->net_income ?? 0; @endphp @endforeach
No. of Family Members Working Days Seasonal / Year-round Distance from Home (km) Wage Rate (₹) Net Income (₹)
{{ $labor->no_of_family_members ?? 'N/A' }} {{ $labor->working_days ?? 'N/A' }} {{ $labor->seasonal_or_year_round ?? 'N/A' }} {{ $labor->distance_from_home_km ?? 'N/A' }} {{ number_format($labor->wage_rate ?? 0, 2) }} {{ number_format($labor->net_income ?? 0, 2) }}
Total Net Income (₹) {{$totalNetIncome}}
@else
No data available: This household has no Daily Wage Labor records.
@endif
Table 1.11 - Source of Family Income
@if($baseline->sourceOfFamilyIncome->count())
@foreach ($baseline->sourceOfFamilyIncome as $source) @endforeach
Occupation Source Type No of Days Engagement Member Involved Annual Income (₹)
{{ $source->occupation ?? 'N/A' }} {{ $source->source_type ?? 'N/A' }} {{ $source->no_of_days_engagement ?? 'N/A' }} {{ $source->member_involved ?? 'N/A' }} {{ $source->annual_income ?? 'N/A' }}
Total Income (₹) {{$baseline->total}}
@else
No data available. This household has no sources of family income.
@endif
@endsection