@extends('layouts.app') @section('title', 'Submit Form') @section('content')
@if($method=='POST')

Submit Form

@else

Edit Form

@endif Back
{{-- Alert Messages --}} @include('common.alert')
{{$form->form_name}}
@if(count($form->formSections)>0)
@csrf @if ($method === 'PUT') @method('PUT') @endif @foreach ($form->formSections as $sectionInfo)
@if (isset($sectionInfo->section->section_name) && $sectionInfo->section->section_name!="")

{{$sectionInfo->section->section_name}}

@endif @if (isset($sectionInfo->section->description) && $sectionInfo->section->description!="")

{{$sectionInfo->section->description}}

@endif
@if(count($sectionInfo->sectionFields)>0) @foreach($sectionInfo->sectionFields as $sectionField) @php $FieldTtype = $sectionField->field_type; $fieldRequired = ""; if($sectionField->field_required==1){ $fieldRequired = "required"; } @endphp
@switch($FieldTtype) @case('textarea') @break @case('date') @break @case('multifile') @break @case('checkbox') @break @case('radio') Yes No @break @default @endswitch
@endforeach @endif
@endforeach
@endif
@endsection @push('script') @endpush