@extends('student/home') @section('content')

Submit Answers on Learning Topic

@if (Session::has('message'))
{{ Session::get('message') }}
@endif {{ Form::open(['method' => 'GET']) }}
{!! Form::label('topic', 'Topic:') !!} {!! Form::select('topicList', $items , $filter, ['class' => 'form-control', 'id' => 'topicList', 'onchange' => 'this.form.submit();']) !!} {{ Form::close() }}
@php ($complete = true)
{!! Form::label('tit1', 'Result of Each Task:') !!} @if ($valid=='0')  Submit a Task Result @endif @foreach($entities as $entity) @if ($valid != '0') @php ($complete = false) @elseif ($entity['status']=='') @php ($complete = false) @else @endif @endforeach
Task No. Description Status Duration Evidence Comment Action
{{ $entity['taskno'] }} {{ $entity['desc'] }}Task result was already validatedNot yet uploaded{{ $entity['status'] }} {{ $entity['duration'] }} minutes {{ $entity['comment'] }}
{{ csrf_field() }}
{{ Form::open(['route'=>'results.store', 'files'=>true]) }}
{!! Form::label('titw2', 'Assignment Answer Submission') !!}
{{ Form::radio('option', 'github' , $option=='github', ['onchange' => 'this.form.submit();']) }} {!! Form::label('tit55', "by GitHub Link: ") !!}
@if (($valid=='0') && ($option=='github'))

The link must be PUBLIC access. Format : https://github.com/{{ '' }}/{{ $currtopic['foldername'] }}/archive/master.zip

{{ Form::text('githublink','https://github.com/', ['class'=>'form-control']) }} @endif

{{ Form::radio('option', 'zipfile' , $option=='zipfile', ['onchange' => 'this.form.submit();']) }} {!! Form::label('tit55', "by Zip File of Android Project Folder: ") !!}
@if (($valid=='0') && ($option=='zipfile'))

File must have ZIP extension (*.zip), don't submit RAR file. The zip file must contain project folder {{ "<".$currtopic['foldername'].">" }}

{{ Form::file('zipfile', ['class'=>'form-control']) }} @endif

{{ Form::radio('option', 'files' , $option=='files', ['onchange' => 'this.form.submit();']) }} {!! Form::label('tit2', 'by Multi Files:') !!} @if ($option=='files') @if ($valid=='0')  Submit a Learning File @endif @foreach($lfiles as $index => $lfile) @if ($valid!='0') @php ($complete = false) @elseif ($lfile['rscfile']=='') @php ($complete = false) @else @endif @endforeach
No. File Name Folder Path Description Status Action
{{ $index +1 }} {{ $lfile['fileName'] }} {{ $lfile['path'] }} {{ $lfile['desc'] }}Task result was already validatedNot yet submitted
@endif


@if ($valid=='0') @if ($complete) {{ Form::submit('Validate This Learning', ['class' => 'btn btn-danger', 'name' => 'submitbutton']) }} @else  Submission is Not Complete @endif @else  Validation is Success @endif
{{ Form::close() }}

@endsection