@extends('user.layouts.app') @section('title','Edit Authors') @section('page-title','Edit Paper Authors') @section('page-subtitle',$paper->paper_code) @section('content') @if(session('success'))
{{ session('success') }}
@endif @if($errors->any())
@endif @if($paper->isAccepted())
This paper has been accepted. Only Technical Committee Editor/Chairman or assigned review managers can change authors.
@else
You can edit, reorder, or remove co-authors until the paper is accepted.
@endif @php $principal = $paper->authors->firstWhere('author_order', 1) ?? $paper->authors->first(); $coAuthors = $paper->authors->where('author_order', '>', 1)->sortBy('author_order')->values()->map(fn ($a) => [ 'first_name' => $a->first_name, 'other_name' => $a->other_name, 'last_name' => $a->last_name, 'email' => $a->email, 'phone' => $a->phone, 'affiliation' => $a->affiliation, ])->all(); @endphp
@csrf @method('PUT') @include('user.partials.paper-author-fields', [ 'coAuthors' => old('authors', $coAuthors), 'principalPhone' => old('principal_phone', $principal?->phone ?? $paper->user?->phone_number), 'principalAffiliation' => old('principal_affiliation', $principal?->affiliation ?? $paper->user?->affiliation), ])
Cancel
@endsection