- ORCID upper case in creator table
- PS2 formating for EditorController, IndexController, SubmitController - all function camel case in HomeController - composer update
This commit is contained in:
parent
25f3175a92
commit
6d0638e201
|
@ -122,7 +122,7 @@ class HomeController extends Controller
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public function php_info()
|
public function phpInfo()
|
||||||
{
|
{
|
||||||
dd(phpinfo());
|
dd(phpinfo());
|
||||||
}
|
}
|
||||||
|
|
|
@ -4,7 +4,6 @@ namespace App\Http\Controllers\Frontend;
|
||||||
use App\Models\Dataset;
|
use App\Models\Dataset;
|
||||||
use App\Http\Controllers\Controller;
|
use App\Http\Controllers\Controller;
|
||||||
use Illuminate\Support\Facades\DB;
|
use Illuminate\Support\Facades\DB;
|
||||||
use DateTime;
|
|
||||||
|
|
||||||
class SitelinkController extends Controller
|
class SitelinkController extends Controller
|
||||||
{
|
{
|
||||||
|
|
|
@ -2,30 +2,30 @@
|
||||||
namespace App\Http\Controllers\Publish;
|
namespace App\Http\Controllers\Publish;
|
||||||
|
|
||||||
use App\Exceptions\GeneralException;
|
use App\Exceptions\GeneralException;
|
||||||
use App\Http\Requests\DocumentRequest;
|
|
||||||
use App\Http\Controllers\Controller;
|
use App\Http\Controllers\Controller;
|
||||||
|
use App\Http\Requests\DocumentRequest;
|
||||||
use App\Models\Dataset;
|
use App\Models\Dataset;
|
||||||
use App\Models\Project;
|
|
||||||
use App\Models\License;
|
|
||||||
use App\Models\User;
|
|
||||||
use App\Models\Title;
|
|
||||||
use App\Models\Description;
|
|
||||||
use App\Models\DatasetReference;
|
use App\Models\DatasetReference;
|
||||||
use App\Models\Subject;
|
use App\Models\Description;
|
||||||
use App\Models\File;
|
use App\Models\File;
|
||||||
|
use App\Models\License;
|
||||||
|
use App\Models\Person;
|
||||||
|
use App\Models\Project;
|
||||||
|
use App\Models\Subject;
|
||||||
|
use App\Models\Title;
|
||||||
|
use App\Models\User;
|
||||||
|
use App\Rules\RdrFilesize;
|
||||||
|
use App\Rules\RdrFiletypes;
|
||||||
|
// use Illuminate\View\View;
|
||||||
|
use Carbon\Carbon;
|
||||||
use Illuminate\Http\RedirectResponse;
|
use Illuminate\Http\RedirectResponse;
|
||||||
use Illuminate\Http\Request;
|
use Illuminate\Http\Request;
|
||||||
use Illuminate\Support\Facades\Auth;
|
use Illuminate\Support\Facades\Auth;
|
||||||
// use Illuminate\View\View;
|
|
||||||
use Illuminate\Support\Facades\View;
|
|
||||||
use Illuminate\Support\Facades\DB;
|
use Illuminate\Support\Facades\DB;
|
||||||
use Illuminate\Support\Facades\Storage;
|
use Illuminate\Support\Facades\Storage;
|
||||||
use Illuminate\Support\Facades\Validator;
|
use Illuminate\Support\Facades\Validator;
|
||||||
use Carbon\Carbon;
|
use Illuminate\Support\Facades\View;
|
||||||
use \Exception;
|
use \Exception;
|
||||||
use App\Rules\RdrFiletypes;
|
|
||||||
use App\Rules\RdrFilesize;
|
|
||||||
use App\Models\Person;
|
|
||||||
|
|
||||||
class EditorController extends Controller
|
class EditorController extends Controller
|
||||||
{
|
{
|
||||||
|
@ -104,7 +104,8 @@ class EditorController extends Controller
|
||||||
$dataset->load('licenses', 'authors', 'contributors', 'titles', 'abstracts', 'files', 'coverage', 'subjects', 'references');
|
$dataset->load('licenses', 'authors', 'contributors', 'titles', 'abstracts', 'files', 'coverage', 'subjects', 'references');
|
||||||
|
|
||||||
$titleTypes = ['Main' => 'Main', 'Sub' => 'Sub', 'Alternative' => 'Alternative', 'Translated' => 'Translated', 'Other' => 'Other'];
|
$titleTypes = ['Main' => 'Main', 'Sub' => 'Sub', 'Alternative' => 'Alternative', 'Translated' => 'Translated', 'Other' => 'Other'];
|
||||||
$descriptionTypes = ['Abstract' => 'Abstract', 'Methods' => 'Methods', 'Series_information' => 'Series_information', 'Technical_info' => 'Technical_info', 'Translated' => 'Translated', 'Other' => 'Other'];
|
$descriptionTypes = ['Abstract' => 'Abstract', 'Methods' => 'Methods', 'Series_information' => 'Series_information',
|
||||||
|
'Technical_info' => 'Technical_info', 'Translated' => 'Translated', 'Other' => 'Other'];
|
||||||
$languages = DB::table('languages')
|
$languages = DB::table('languages')
|
||||||
->where('active', true)
|
->where('active', true)
|
||||||
->pluck('part1', 'part1');
|
->pluck('part1', 'part1');
|
||||||
|
@ -137,10 +138,12 @@ class EditorController extends Controller
|
||||||
$referenceTypes = ["rdr-id", "doi", "handle", "isbn", "issn", "url", "urn"];
|
$referenceTypes = ["rdr-id", "doi", "handle", "isbn", "issn", "url", "urn"];
|
||||||
$referenceTypes = array_combine($referenceTypes, $referenceTypes);
|
$referenceTypes = array_combine($referenceTypes, $referenceTypes);
|
||||||
|
|
||||||
$relationTypes = ["IsCitedBy", "Cites", "IsSupplementTo", "IsSupplementedBy", "IsContinuedBy", "Continues", "HasMetadata", "IsMetadataFor", "IsNewVersionOf", "IsPreviousVersionOf", "IsPartOf", "HasPart", "IsReferencedBy", "References", "IsDocumentedBy", "Documents", "IsCompiledBy", "Compiles", "IsVariantFormOf", "IsOriginalFormOf", "IsIdenticalTo", "IsReviewedBy", "Reviews", "IsDerivedFrom", "IsSourceOf"];
|
$relationTypes = ["IsCitedBy", "Cites", "IsSupplementTo", "IsSupplementedBy", "IsContinuedBy", "Continues",
|
||||||
|
"HasMetadata", "IsMetadataFor", "IsNewVersionOf", "IsPreviousVersionOf", "IsPartOf", "HasPart", "IsReferencedBy",
|
||||||
|
"References", "IsDocumentedBy", "Documents", "IsCompiledBy", "Compiles", "IsVariantFormOf", "IsOriginalFormOf",
|
||||||
|
"IsIdenticalTo", "IsReviewedBy", "Reviews", "IsDerivedFrom", "IsSourceOf"];
|
||||||
$relationTypes = array_combine($relationTypes, $relationTypes);
|
$relationTypes = array_combine($relationTypes, $relationTypes);
|
||||||
|
|
||||||
|
|
||||||
return View::make(
|
return View::make(
|
||||||
'workflow.editor.edit',
|
'workflow.editor.edit',
|
||||||
compact(
|
compact(
|
||||||
|
@ -180,19 +183,19 @@ class EditorController extends Controller
|
||||||
'descriptions.*.language' => 'required',
|
'descriptions.*.language' => 'required',
|
||||||
'coverage.x_min' => [
|
'coverage.x_min' => [
|
||||||
'required',
|
'required',
|
||||||
'regex:/^[-]?((((1[0-7][0-9])|([0-9]?[0-9]))\.(\d+))|180(\.0+)?)$/'
|
'regex:/^[-]?((((1[0-7][0-9])|([0-9]?[0-9]))\.(\d+))|180(\.0+)?)$/',
|
||||||
],
|
],
|
||||||
'coverage.y_min' => [
|
'coverage.y_min' => [
|
||||||
'required',
|
'required',
|
||||||
'regex:/^[-]?(([0-8]?[0-9])\.(\d+))|(90(\.0+)?)$/'
|
'regex:/^[-]?(([0-8]?[0-9])\.(\d+))|(90(\.0+)?)$/',
|
||||||
],
|
],
|
||||||
'coverage.x_max' => [
|
'coverage.x_max' => [
|
||||||
'required',
|
'required',
|
||||||
'regex:/^[-]?((((1[0-7][0-9])|([0-9]?[0-9]))\.(\d+))|180(\.0+)?)$/'
|
'regex:/^[-]?((((1[0-7][0-9])|([0-9]?[0-9]))\.(\d+))|180(\.0+)?)$/',
|
||||||
],
|
],
|
||||||
'coverage.y_max' => [
|
'coverage.y_max' => [
|
||||||
'required',
|
'required',
|
||||||
'regex:/^[-]?(([0-8]?[0-9])\.(\d+))|(90(\.0+)?)$/'
|
'regex:/^[-]?(([0-8]?[0-9])\.(\d+))|(90(\.0+)?)$/',
|
||||||
],
|
],
|
||||||
'subjects' => 'required|array|min:3',
|
'subjects' => 'required|array|min:3',
|
||||||
'subjects.*.value' => 'required|string',
|
'subjects.*.value' => 'required|string',
|
||||||
|
@ -373,10 +376,9 @@ class EditorController extends Controller
|
||||||
$fileIndex = $formFile['file'];
|
$fileIndex = $formFile['file'];
|
||||||
$file = $uploads[$fileIndex];
|
$file = $uploads[$fileIndex];
|
||||||
|
|
||||||
|
|
||||||
// $file = new \Illuminate\Http\UploadedFile($file);
|
// $file = new \Illuminate\Http\UploadedFile($file);
|
||||||
$label = urldecode($formFile['label']);
|
$label = urldecode($formFile['label']);
|
||||||
$sort_order = $index;//$formFile['sort_order'];
|
$sort_order = $index; //$formFile['sort_order'];
|
||||||
$fileName = "file-" . time() . '.' . $file->getClientOriginalExtension();
|
$fileName = "file-" . time() . '.' . $file->getClientOriginalExtension();
|
||||||
$mimeType = $file->getMimeType();
|
$mimeType = $file->getMimeType();
|
||||||
$datasetFolder = 'files/' . $dataset->id;
|
$datasetFolder = 'files/' . $dataset->id;
|
||||||
|
@ -390,7 +392,7 @@ class EditorController extends Controller
|
||||||
'label' => $label,
|
'label' => $label,
|
||||||
'sort_order' => $sort_order,
|
'sort_order' => $sort_order,
|
||||||
'visible_in_frontdoor' => 1,
|
'visible_in_frontdoor' => 1,
|
||||||
'visible_in_oai' => 1
|
'visible_in_oai' => 1,
|
||||||
]);
|
]);
|
||||||
//$test = $file->path_name;
|
//$test = $file->path_name;
|
||||||
$dataset->files()->save($fileDb);
|
$dataset->files()->save($fileDb);
|
||||||
|
@ -524,7 +526,7 @@ class EditorController extends Controller
|
||||||
{
|
{
|
||||||
$this->validate($request, [
|
$this->validate($request, [
|
||||||
'reject_editor_note' => 'required|min:10|max:500',
|
'reject_editor_note' => 'required|min:10|max:500',
|
||||||
'server_state' => 'required'
|
'server_state' => 'required',
|
||||||
]);
|
]);
|
||||||
$dataset = Dataset::findOrFail($id);
|
$dataset = Dataset::findOrFail($id);
|
||||||
$input = $request->all();
|
$input = $request->all();
|
||||||
|
@ -552,7 +554,7 @@ class EditorController extends Controller
|
||||||
'titles',
|
'titles',
|
||||||
'persons' => function ($query) {
|
'persons' => function ($query) {
|
||||||
$query->wherePivot('role', 'author');
|
$query->wherePivot('role', 'author');
|
||||||
}
|
},
|
||||||
])->findOrFail($id);
|
])->findOrFail($id);
|
||||||
|
|
||||||
return View::make('workflow.editor.publish', [
|
return View::make('workflow.editor.publish', [
|
||||||
|
@ -567,7 +569,7 @@ class EditorController extends Controller
|
||||||
$max = Dataset::max('publish_id');
|
$max = Dataset::max('publish_id');
|
||||||
$publish_id = 0;
|
$publish_id = 0;
|
||||||
if ($max != null) {
|
if ($max != null) {
|
||||||
$publish_id = $max +1;
|
$publish_id = $max + 1;
|
||||||
} else {
|
} else {
|
||||||
$publish_id = $publish_id + 1;
|
$publish_id = $publish_id + 1;
|
||||||
}
|
}
|
||||||
|
|
|
@ -2,25 +2,25 @@
|
||||||
//https://www.5balloons.info/multi-page-step-form-in-laravel-with-validation/
|
//https://www.5balloons.info/multi-page-step-form-in-laravel-with-validation/
|
||||||
namespace App\Http\Controllers\Publish;
|
namespace App\Http\Controllers\Publish;
|
||||||
|
|
||||||
use App\Models\Dataset;
|
|
||||||
use App\Http\Controllers\Controller;
|
use App\Http\Controllers\Controller;
|
||||||
use App\Models\License;
|
use App\Models\Coverage;
|
||||||
use App\Models\File;
|
use App\Models\Dataset;
|
||||||
use App\Models\Project;
|
use App\Models\DatasetReference;
|
||||||
use App\Models\Title;
|
|
||||||
use App\Models\Description;
|
use App\Models\Description;
|
||||||
use App\Rules\RdrFiletypes;
|
use App\Models\File;
|
||||||
|
use App\Models\License;
|
||||||
|
use App\Models\Page;
|
||||||
|
use App\Models\Person;
|
||||||
|
use App\Models\Project;
|
||||||
|
use App\Models\Subject;
|
||||||
|
use App\Models\Title;
|
||||||
use App\Rules\RdrFilesize;
|
use App\Rules\RdrFilesize;
|
||||||
|
use App\Rules\RdrFiletypes;
|
||||||
use Illuminate\Http\Request;
|
use Illuminate\Http\Request;
|
||||||
|
use Illuminate\Support\Facades\Auth;
|
||||||
use Illuminate\Support\Facades\DB;
|
use Illuminate\Support\Facades\DB;
|
||||||
use Illuminate\Support\Facades\Storage;
|
use Illuminate\Support\Facades\Storage;
|
||||||
use Illuminate\Support\Facades\Validator;
|
use Illuminate\Support\Facades\Validator;
|
||||||
use App\Models\DatasetReference;
|
|
||||||
use App\Models\Subject;
|
|
||||||
use App\Models\Page;
|
|
||||||
use App\Models\Person;
|
|
||||||
use Illuminate\Support\Facades\Auth;
|
|
||||||
use App\Models\Coverage;
|
|
||||||
|
|
||||||
class IndexController extends Controller
|
class IndexController extends Controller
|
||||||
{
|
{
|
||||||
|
@ -62,14 +62,18 @@ class IndexController extends Controller
|
||||||
$relatedIdentifierTypes = ["doi", "handle", "isbn", "issn", "url", "urn"];
|
$relatedIdentifierTypes = ["doi", "handle", "isbn", "issn", "url", "urn"];
|
||||||
$relatedIdentifierTypes = array_combine($relatedIdentifierTypes, $relatedIdentifierTypes);
|
$relatedIdentifierTypes = array_combine($relatedIdentifierTypes, $relatedIdentifierTypes);
|
||||||
|
|
||||||
$relationTypes = ["IsCitedBy", "Cites", "IsSupplementTo", "IsSupplementedBy", "IsContinuedBy", "Continues", "HasMetadata", "IsMetadataFor","IsNewVersionOf", "IsPreviousVersionOf", "IsPartOf", "HasPart", "IsReferencedBy", "References", "IsDocumentedBy", "Documents", "IsCompiledBy", "Compiles", "IsVariantFormOf", "IsOriginalFormOf", "IsIdenticalTo", "IsReviewedBy", "Reviews", "IsDerivedFrom", "IsSourceOf"];
|
$relationTypes = ["IsCitedBy", "Cites", "IsSupplementTo", "IsSupplementedBy", "IsContinuedBy", "Continues",
|
||||||
|
"HasMetadata", "IsMetadataFor", "IsNewVersionOf", "IsPreviousVersionOf", "IsPartOf", "HasPart", "IsReferencedBy",
|
||||||
|
"References", "IsDocumentedBy", "Documents", "IsCompiledBy", "Compiles", "IsVariantFormOf", "IsOriginalFormOf",
|
||||||
|
"IsIdenticalTo", "IsReviewedBy", "Reviews", "IsDerivedFrom", "IsSourceOf"];
|
||||||
$relationTypes = array_combine($relationTypes, $relationTypes);
|
$relationTypes = array_combine($relationTypes, $relationTypes);
|
||||||
|
|
||||||
$titleTypes = ['Sub' => 'Sub', 'Alternative' => 'Alternative', 'Translated' => 'Translated', 'Other' => 'Other'];
|
$titleTypes = ['Sub' => 'Sub', 'Alternative' => 'Alternative', 'Translated' => 'Translated', 'Other' => 'Other'];
|
||||||
|
|
||||||
$keywordTypes = ['uncontrolled' => 'uncontrolled'];
|
$keywordTypes = ['uncontrolled' => 'uncontrolled'];
|
||||||
|
|
||||||
$descriptionTypes = ['Methods' => 'Methods', 'Series_information' => 'Series_information', 'Technical_info' => 'Technical_info', 'Translated' => 'Translated', 'Other' => 'Other'];
|
$descriptionTypes = ['Methods' => 'Methods', 'Series_information' => 'Series_information',
|
||||||
|
'Technical_info' => 'Technical_info', 'Translated' => 'Translated', 'Other' => 'Other'];
|
||||||
|
|
||||||
$page = Page::query()->where('page_slug', 'terms-and-conditions')->firstOrFail();
|
$page = Page::query()->where('page_slug', 'terms-and-conditions')->firstOrFail();
|
||||||
|
|
||||||
|
@ -257,19 +261,19 @@ class IndexController extends Controller
|
||||||
'descriptions.*.value' => 'required|min:4|max:2500',
|
'descriptions.*.value' => 'required|min:4|max:2500',
|
||||||
'coverage.x_min' => [
|
'coverage.x_min' => [
|
||||||
'required',
|
'required',
|
||||||
'regex:/^[-]?((((1[0-7][0-9])|([0-9]?[0-9]))\.(\d+))|180(\.0+)?)$/'
|
'regex:/^[-]?((((1[0-7][0-9])|([0-9]?[0-9]))\.(\d+))|180(\.0+)?)$/',
|
||||||
],
|
],
|
||||||
'coverage.y_min' => [
|
'coverage.y_min' => [
|
||||||
'required',
|
'required',
|
||||||
'regex:/^[-]?(([0-8]?[0-9])\.(\d+))|(90(\.0+)?)$/'
|
'regex:/^[-]?(([0-8]?[0-9])\.(\d+))|(90(\.0+)?)$/',
|
||||||
],
|
],
|
||||||
'coverage.x_max' => [
|
'coverage.x_max' => [
|
||||||
'required',
|
'required',
|
||||||
'regex:/^[-]?((((1[0-7][0-9])|([0-9]?[0-9]))\.(\d+))|180(\.0+)?)$/'
|
'regex:/^[-]?((((1[0-7][0-9])|([0-9]?[0-9]))\.(\d+))|180(\.0+)?)$/',
|
||||||
],
|
],
|
||||||
'coverage.y_max' => [
|
'coverage.y_max' => [
|
||||||
'required',
|
'required',
|
||||||
'regex:/^[-]?(([0-8]?[0-9])\.(\d+))|(90(\.0+)?)$/'
|
'regex:/^[-]?(([0-8]?[0-9])\.(\d+))|(90(\.0+)?)$/',
|
||||||
],
|
],
|
||||||
'keywords' => 'required|array|min:3',
|
'keywords' => 'required|array|min:3',
|
||||||
'keywords.*.value' => 'required|string',
|
'keywords.*.value' => 'required|string',
|
||||||
|
@ -336,7 +340,7 @@ class IndexController extends Controller
|
||||||
'label' => $label,
|
'label' => $label,
|
||||||
'sort_order' => $sorting,
|
'sort_order' => $sorting,
|
||||||
'visible_in_frontdoor' => 1,
|
'visible_in_frontdoor' => 1,
|
||||||
'visible_in_oai' => 1
|
'visible_in_oai' => 1,
|
||||||
]);
|
]);
|
||||||
//$test = $file->path_name;
|
//$test = $file->path_name;
|
||||||
$dataset->files()->save($file);
|
$dataset->files()->save($file);
|
||||||
|
@ -405,7 +409,6 @@ class IndexController extends Controller
|
||||||
// }
|
// }
|
||||||
//$dataset->persons()->sync($data_to_sync);
|
//$dataset->persons()->sync($data_to_sync);
|
||||||
|
|
||||||
|
|
||||||
//save main title:
|
//save main title:
|
||||||
if (isset($data['title_main'])) {
|
if (isset($data['title_main'])) {
|
||||||
$formTitle = $request->input('title_main');
|
$formTitle = $request->input('title_main');
|
||||||
|
@ -549,7 +552,7 @@ class IndexController extends Controller
|
||||||
'abstract_main.language' => 'required',
|
'abstract_main.language' => 'required',
|
||||||
];
|
];
|
||||||
if (null != $request->file('files')) {
|
if (null != $request->file('files')) {
|
||||||
$files = count($request->file('files')) -1;
|
$files = count($request->file('files')) - 1;
|
||||||
foreach (range(0, $files) as $index) {
|
foreach (range(0, $files) as $index) {
|
||||||
// $rules['files.' . $index] = 'image|max:2048';
|
// $rules['files.' . $index] = 'image|max:2048';
|
||||||
$rules['files.' . $index . '.file'] = ['required', 'file', new RdrFiletypes(), new RdrFilesize($index)];
|
$rules['files.' . $index . '.file'] = ['required', 'file', new RdrFiletypes(), new RdrFilesize($index)];
|
||||||
|
@ -629,7 +632,6 @@ class IndexController extends Controller
|
||||||
// $dataset->persons()->sync($data_to_sync);
|
// $dataset->persons()->sync($data_to_sync);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//save main title:
|
//save main title:
|
||||||
if (isset($data['title_main'])) {
|
if (isset($data['title_main'])) {
|
||||||
$formTitle = $request->input('title_main');
|
$formTitle = $request->input('title_main');
|
||||||
|
|
|
@ -16,6 +16,8 @@ use App\Models\Project;
|
||||||
use App\Models\Subject;
|
use App\Models\Subject;
|
||||||
use App\Models\Title;
|
use App\Models\Title;
|
||||||
use App\Models\User;
|
use App\Models\User;
|
||||||
|
use App\Rules\RdrFilesize;
|
||||||
|
use App\Rules\RdrFiletypes;
|
||||||
use Exception;
|
use Exception;
|
||||||
use Illuminate\Http\RedirectResponse;
|
use Illuminate\Http\RedirectResponse;
|
||||||
use Illuminate\Http\Request;
|
use Illuminate\Http\Request;
|
||||||
|
@ -24,8 +26,6 @@ use Illuminate\Support\Facades\DB;
|
||||||
use Illuminate\Support\Facades\Storage;
|
use Illuminate\Support\Facades\Storage;
|
||||||
use Illuminate\Support\Facades\Validator;
|
use Illuminate\Support\Facades\Validator;
|
||||||
use Illuminate\Support\Facades\View;
|
use Illuminate\Support\Facades\View;
|
||||||
use App\Rules\RdrFiletypes;
|
|
||||||
use App\Rules\RdrFilesize;
|
|
||||||
|
|
||||||
class SubmitController extends Controller
|
class SubmitController extends Controller
|
||||||
{
|
{
|
||||||
|
@ -65,7 +65,8 @@ class SubmitController extends Controller
|
||||||
$dataset->load('licenses', 'authors', 'contributors', 'titles', 'abstracts', 'files', 'coverage', 'subjects', 'references');
|
$dataset->load('licenses', 'authors', 'contributors', 'titles', 'abstracts', 'files', 'coverage', 'subjects', 'references');
|
||||||
|
|
||||||
$titleTypes = ['Main' => 'Main', 'Sub' => 'Sub', 'Alternative' => 'Alternative', 'Translated' => 'Translated', 'Other' => 'Other'];
|
$titleTypes = ['Main' => 'Main', 'Sub' => 'Sub', 'Alternative' => 'Alternative', 'Translated' => 'Translated', 'Other' => 'Other'];
|
||||||
$descriptionTypes = ['Abstract' => 'Abstract', 'Methods' => 'Methods', 'Series_information' => 'Series_information', 'Technical_info' => 'Technical_info', 'Translated' => 'Translated', 'Other' => 'Other'];
|
$descriptionTypes = ['Abstract' => 'Abstract', 'Methods' => 'Methods', 'Series_information' => 'Series_information',
|
||||||
|
'Technical_info' => 'Technical_info', 'Translated' => 'Translated', 'Other' => 'Other'];
|
||||||
$languages = DB::table('languages')
|
$languages = DB::table('languages')
|
||||||
->where('active', true)
|
->where('active', true)
|
||||||
->pluck('part1', 'part1');
|
->pluck('part1', 'part1');
|
||||||
|
@ -98,7 +99,10 @@ class SubmitController extends Controller
|
||||||
$referenceTypes = ["rdr-id", "doi", "handle", "isbn", "issn", "url", "urn"];
|
$referenceTypes = ["rdr-id", "doi", "handle", "isbn", "issn", "url", "urn"];
|
||||||
$referenceTypes = array_combine($referenceTypes, $referenceTypes);
|
$referenceTypes = array_combine($referenceTypes, $referenceTypes);
|
||||||
|
|
||||||
$relationTypes = ["IsCitedBy", "Cites", "IsSupplementTo", "IsSupplementedBy", "IsContinuedBy", "Continues", "HasMetadata", "IsMetadataFor", "IsNewVersionOf", "IsPreviousVersionOf", "IsPartOf", "HasPart", "IsReferencedBy", "References", "IsDocumentedBy", "Documents", "IsCompiledBy", "Compiles", "IsVariantFormOf", "IsOriginalFormOf", "IsIdenticalTo", "IsReviewedBy", "Reviews", "IsDerivedFrom", "IsSourceOf"];
|
$relationTypes = ["IsCitedBy", "Cites", "IsSupplementTo", "IsSupplementedBy", "IsContinuedBy", "Continues",
|
||||||
|
"HasMetadata", "IsMetadataFor", "IsNewVersionOf", "IsPreviousVersionOf", "IsPartOf", "HasPart", "IsReferencedBy",
|
||||||
|
"References", "IsDocumentedBy", "Documents", "IsCompiledBy", "Compiles", "IsVariantFormOf", "IsOriginalFormOf",
|
||||||
|
"IsIdenticalTo", "IsReviewedBy", "Reviews", "IsDerivedFrom", "IsSourceOf"];
|
||||||
$relationTypes = array_combine($relationTypes, $relationTypes);
|
$relationTypes = array_combine($relationTypes, $relationTypes);
|
||||||
|
|
||||||
return View::make(
|
return View::make(
|
||||||
|
@ -140,19 +144,19 @@ class SubmitController extends Controller
|
||||||
'descriptions.*.language' => 'required',
|
'descriptions.*.language' => 'required',
|
||||||
'coverage.x_min' => [
|
'coverage.x_min' => [
|
||||||
'required',
|
'required',
|
||||||
'regex:/^[-]?((((1[0-7][0-9])|([0-9]?[0-9]))\.(\d+))|180(\.0+)?)$/'
|
'regex:/^[-]?((((1[0-7][0-9])|([0-9]?[0-9]))\.(\d+))|180(\.0+)?)$/',
|
||||||
],
|
],
|
||||||
'coverage.y_min' => [
|
'coverage.y_min' => [
|
||||||
'required',
|
'required',
|
||||||
'regex:/^[-]?(([0-8]?[0-9])\.(\d+))|(90(\.0+)?)$/'
|
'regex:/^[-]?(([0-8]?[0-9])\.(\d+))|(90(\.0+)?)$/',
|
||||||
],
|
],
|
||||||
'coverage.x_max' => [
|
'coverage.x_max' => [
|
||||||
'required',
|
'required',
|
||||||
'regex:/^[-]?((((1[0-7][0-9])|([0-9]?[0-9]))\.(\d+))|180(\.0+)?)$/'
|
'regex:/^[-]?((((1[0-7][0-9])|([0-9]?[0-9]))\.(\d+))|180(\.0+)?)$/',
|
||||||
],
|
],
|
||||||
'coverage.y_max' => [
|
'coverage.y_max' => [
|
||||||
'required',
|
'required',
|
||||||
'regex:/^[-]?(([0-8]?[0-9])\.(\d+))|(90(\.0+)?)$/'
|
'regex:/^[-]?(([0-8]?[0-9])\.(\d+))|(90(\.0+)?)$/',
|
||||||
],
|
],
|
||||||
'subjects' => 'required|array|min:3',
|
'subjects' => 'required|array|min:3',
|
||||||
'subjects.*.value' => 'required|string',
|
'subjects.*.value' => 'required|string',
|
||||||
|
@ -333,10 +337,9 @@ class SubmitController extends Controller
|
||||||
$fileIndex = $formFile['file'];
|
$fileIndex = $formFile['file'];
|
||||||
$file = $uploads[$fileIndex];
|
$file = $uploads[$fileIndex];
|
||||||
|
|
||||||
|
|
||||||
// $file = new \Illuminate\Http\UploadedFile($file);
|
// $file = new \Illuminate\Http\UploadedFile($file);
|
||||||
$label = urldecode($formFile['label']);
|
$label = urldecode($formFile['label']);
|
||||||
$sort_order = $index;//$formFile['sort_order'];
|
$sort_order = $index; //$formFile['sort_order'];
|
||||||
$fileName = "file-" . time() . '.' . $file->getClientOriginalExtension();
|
$fileName = "file-" . time() . '.' . $file->getClientOriginalExtension();
|
||||||
$mimeType = $file->getMimeType();
|
$mimeType = $file->getMimeType();
|
||||||
$datasetFolder = 'files/' . $dataset->id;
|
$datasetFolder = 'files/' . $dataset->id;
|
||||||
|
@ -350,7 +353,7 @@ class SubmitController extends Controller
|
||||||
'label' => $label,
|
'label' => $label,
|
||||||
'sort_order' => $sort_order,
|
'sort_order' => $sort_order,
|
||||||
'visible_in_frontdoor' => 1,
|
'visible_in_frontdoor' => 1,
|
||||||
'visible_in_oai' => 1
|
'visible_in_oai' => 1,
|
||||||
]);
|
]);
|
||||||
//$test = $file->path_name;
|
//$test = $file->path_name;
|
||||||
$dataset->files()->save($fileDb);
|
$dataset->files()->save($fileDb);
|
||||||
|
|
|
@ -23,8 +23,7 @@
|
||||||
},
|
},
|
||||||
"require-dev": {
|
"require-dev": {
|
||||||
"fzaninotto/faker": "^1.8",
|
"fzaninotto/faker": "^1.8",
|
||||||
"phpunit/phpunit": "^7.0",
|
"phpunit/phpunit": "^7.0"
|
||||||
"squizlabs/php_codesniffer": "^3.4"
|
|
||||||
},
|
},
|
||||||
"autoload": {
|
"autoload": {
|
||||||
"files": [
|
"files": [
|
||||||
|
|
77
composer.lock
generated
77
composer.lock
generated
|
@ -4,7 +4,7 @@
|
||||||
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
|
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
|
||||||
"This file is @generated automatically"
|
"This file is @generated automatically"
|
||||||
],
|
],
|
||||||
"content-hash": "211b7ec765465de1612277be49ffc92f",
|
"content-hash": "8bb6d0c35adaea7dda9a8f822bafa019",
|
||||||
"packages": [
|
"packages": [
|
||||||
{
|
{
|
||||||
"name": "astrotomic/laravel-translatable",
|
"name": "astrotomic/laravel-translatable",
|
||||||
|
@ -548,24 +548,24 @@
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "fideloper/proxy",
|
"name": "fideloper/proxy",
|
||||||
"version": "4.2.2",
|
"version": "4.3.0",
|
||||||
"source": {
|
"source": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
"url": "https://github.com/fideloper/TrustedProxy.git",
|
"url": "https://github.com/fideloper/TrustedProxy.git",
|
||||||
"reference": "790194d5d3da89a713478875d2e2d05855a90a81"
|
"reference": "ec38ad69ee378a1eec04fb0e417a97cfaf7ed11a"
|
||||||
},
|
},
|
||||||
"dist": {
|
"dist": {
|
||||||
"type": "zip",
|
"type": "zip",
|
||||||
"url": "https://api.github.com/repos/fideloper/TrustedProxy/zipball/790194d5d3da89a713478875d2e2d05855a90a81",
|
"url": "https://api.github.com/repos/fideloper/TrustedProxy/zipball/ec38ad69ee378a1eec04fb0e417a97cfaf7ed11a",
|
||||||
"reference": "790194d5d3da89a713478875d2e2d05855a90a81",
|
"reference": "ec38ad69ee378a1eec04fb0e417a97cfaf7ed11a",
|
||||||
"shasum": ""
|
"shasum": ""
|
||||||
},
|
},
|
||||||
"require": {
|
"require": {
|
||||||
"illuminate/contracts": "^5.0|^6.0|^7.0",
|
"illuminate/contracts": "^5.0|^6.0|^7.0|^8.0",
|
||||||
"php": ">=5.4.0"
|
"php": ">=5.4.0"
|
||||||
},
|
},
|
||||||
"require-dev": {
|
"require-dev": {
|
||||||
"illuminate/http": "^5.0|^6.0|^7.0",
|
"illuminate/http": "^5.0|^6.0|^7.0|^8.0",
|
||||||
"mockery/mockery": "^1.0",
|
"mockery/mockery": "^1.0",
|
||||||
"phpunit/phpunit": "^6.0"
|
"phpunit/phpunit": "^6.0"
|
||||||
},
|
},
|
||||||
|
@ -598,7 +598,7 @@
|
||||||
"proxy",
|
"proxy",
|
||||||
"trusted proxy"
|
"trusted proxy"
|
||||||
],
|
],
|
||||||
"time": "2019-12-20T13:11:11+00:00"
|
"time": "2020-02-22T01:51:47+00:00"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "jakub-onderka/php-console-color",
|
"name": "jakub-onderka/php-console-color",
|
||||||
|
@ -1694,16 +1694,16 @@
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "ramsey/uuid",
|
"name": "ramsey/uuid",
|
||||||
"version": "3.9.2",
|
"version": "3.9.3",
|
||||||
"source": {
|
"source": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
"url": "https://github.com/ramsey/uuid.git",
|
"url": "https://github.com/ramsey/uuid.git",
|
||||||
"reference": "7779489a47d443f845271badbdcedfe4df8e06fb"
|
"reference": "7e1633a6964b48589b142d60542f9ed31bd37a92"
|
||||||
},
|
},
|
||||||
"dist": {
|
"dist": {
|
||||||
"type": "zip",
|
"type": "zip",
|
||||||
"url": "https://api.github.com/repos/ramsey/uuid/zipball/7779489a47d443f845271badbdcedfe4df8e06fb",
|
"url": "https://api.github.com/repos/ramsey/uuid/zipball/7e1633a6964b48589b142d60542f9ed31bd37a92",
|
||||||
"reference": "7779489a47d443f845271badbdcedfe4df8e06fb",
|
"reference": "7e1633a6964b48589b142d60542f9ed31bd37a92",
|
||||||
"shasum": ""
|
"shasum": ""
|
||||||
},
|
},
|
||||||
"require": {
|
"require": {
|
||||||
|
@ -1777,7 +1777,7 @@
|
||||||
"identifier",
|
"identifier",
|
||||||
"uuid"
|
"uuid"
|
||||||
],
|
],
|
||||||
"time": "2019-12-17T08:18:51+00:00"
|
"time": "2020-02-21T04:36:14+00:00"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "solarium/solarium",
|
"name": "solarium/solarium",
|
||||||
|
@ -4897,57 +4897,6 @@
|
||||||
"homepage": "https://github.com/sebastianbergmann/version",
|
"homepage": "https://github.com/sebastianbergmann/version",
|
||||||
"time": "2016-10-03T07:35:21+00:00"
|
"time": "2016-10-03T07:35:21+00:00"
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"name": "squizlabs/php_codesniffer",
|
|
||||||
"version": "3.5.4",
|
|
||||||
"source": {
|
|
||||||
"type": "git",
|
|
||||||
"url": "https://github.com/squizlabs/PHP_CodeSniffer.git",
|
|
||||||
"reference": "dceec07328401de6211037abbb18bda423677e26"
|
|
||||||
},
|
|
||||||
"dist": {
|
|
||||||
"type": "zip",
|
|
||||||
"url": "https://api.github.com/repos/squizlabs/PHP_CodeSniffer/zipball/dceec07328401de6211037abbb18bda423677e26",
|
|
||||||
"reference": "dceec07328401de6211037abbb18bda423677e26",
|
|
||||||
"shasum": ""
|
|
||||||
},
|
|
||||||
"require": {
|
|
||||||
"ext-simplexml": "*",
|
|
||||||
"ext-tokenizer": "*",
|
|
||||||
"ext-xmlwriter": "*",
|
|
||||||
"php": ">=5.4.0"
|
|
||||||
},
|
|
||||||
"require-dev": {
|
|
||||||
"phpunit/phpunit": "^4.0 || ^5.0 || ^6.0 || ^7.0"
|
|
||||||
},
|
|
||||||
"bin": [
|
|
||||||
"bin/phpcs",
|
|
||||||
"bin/phpcbf"
|
|
||||||
],
|
|
||||||
"type": "library",
|
|
||||||
"extra": {
|
|
||||||
"branch-alias": {
|
|
||||||
"dev-master": "3.x-dev"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"notification-url": "https://packagist.org/downloads/",
|
|
||||||
"license": [
|
|
||||||
"BSD-3-Clause"
|
|
||||||
],
|
|
||||||
"authors": [
|
|
||||||
{
|
|
||||||
"name": "Greg Sherwood",
|
|
||||||
"role": "lead"
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"description": "PHP_CodeSniffer tokenizes PHP, JavaScript and CSS files and detects violations of a defined set of coding standards.",
|
|
||||||
"homepage": "https://github.com/squizlabs/PHP_CodeSniffer",
|
|
||||||
"keywords": [
|
|
||||||
"phpcs",
|
|
||||||
"standards"
|
|
||||||
],
|
|
||||||
"time": "2020-01-30T22:20:29+00:00"
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"name": "theseer/tokenizer",
|
"name": "theseer/tokenizer",
|
||||||
"version": "1.1.3",
|
"version": "1.1.3",
|
||||||
|
|
|
@ -18,7 +18,8 @@ class MessagesTableSeeder extends Seeder
|
||||||
[
|
[
|
||||||
// 1
|
// 1
|
||||||
'metadata_element' => 'dataset_language',
|
'metadata_element' => 'dataset_language',
|
||||||
'help_text' => 'In Abhängigkeit der Publikationssprache sollten die Metadaten in Englisch oder Deutsch eingegeben werden.',
|
'help_text' => 'In Abhängigkeit der Publikationssprache sollten
|
||||||
|
die Metadaten in Englisch oder Deutsch eingegeben werden.',
|
||||||
'created_at' => Carbon::now(),
|
'created_at' => Carbon::now(),
|
||||||
'updated_at' => Carbon::now(),
|
'updated_at' => Carbon::now(),
|
||||||
],
|
],
|
||||||
|
|
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
@ -12,7 +12,7 @@
|
||||||
<th scope="col">
|
<th scope="col">
|
||||||
<label for="language">
|
<label for="language">
|
||||||
<span>
|
<span>
|
||||||
Orcid <i
|
ORCID <i
|
||||||
v-tooltip="{ content: messages.orcid, class: 'tooltip-custom tooltip-other-custom' }"
|
v-tooltip="{ content: messages.orcid, class: 'tooltip-custom tooltip-other-custom' }"
|
||||||
class="far fa-lg fa-question-circle"
|
class="far fa-lg fa-question-circle"
|
||||||
></i>
|
></i>
|
||||||
|
|
|
@ -454,7 +454,7 @@ Route::group(['namespace' => 'Frontend', 'as' => 'frontend.'], function () {
|
||||||
'as' => 'home.help', 'uses' => 'HomeController@help',
|
'as' => 'home.help', 'uses' => 'HomeController@help',
|
||||||
]);
|
]);
|
||||||
Route::get('/info', [
|
Route::get('/info', [
|
||||||
'as' => 'home.php_info', 'uses' => 'HomeController@php_info',
|
'as' => 'home.php_info', 'uses' => 'HomeController@phpInfo',
|
||||||
]);
|
]);
|
||||||
|
|
||||||
//=================================================Crawlers====================================================
|
//=================================================Crawlers====================================================
|
||||||
|
|
Loading…
Reference in New Issue
Block a user