@extends('layouts.app') @section('content')

{{ __('contract.change.title') }}


@foreach ( $contract['questionGroups'] as $group )

{{ $group['label'] }}

@foreach ( $group['questions'] as $question ) {!! $form->index( 'summary', $question ) !!} @foreach ( $group['vote'] as $vote ) @if( $vote['data'] === 'declined' || $vote['data'] === 'pending' ) {!! $form->index( 'edit', $question, 'd-none question-change-data' ) !!} @elseif( $vote['data'] === 'accepted' && isset($group['masterReviewable']) && $group['masterReviewable'] == true ) {!! $form->index( 'edit', $question, 'd-none question-change-data' ) !!} @endif @endforeach @endforeach @if ( $contract[ 'status' ] != 'review' ) @php if( isset( $_COOKIE['changeAlert'] ) && json_decode( base64_decode( $_COOKIE['changeAlert'] ) )->contractId == $contract['id'] ) $changeAlert = json_decode( base64_decode( $_COOKIE['changeAlert'] ) )->alertVisible; @endphp @foreach ( $group['vote'] as $vote ) @if( isset($group['masterReviewable']) && $group['masterReviewable'] == true ) {!! $form->change_data( $vote['data'], $group['masterReviewable'], isset( $changeAlert ) ? $changeAlert[$loop->parent->index] : true ) !!} @else {!! $form->change_data( $vote['data'], false, isset( $changeAlert ) ? $changeAlert[$loop->parent->index] : true ) !!} @endif @endforeach @endif
@endforeach
@endsection