- map 'id' of dataset to 'publish_id'
This commit is contained in:
parent
d7cc8d74de
commit
19e2d7ea95
7 changed files with 18 additions and 16 deletions
|
@ -50,7 +50,7 @@ class SitelinkController extends Controller
|
|||
->whereYear('server_date_published', '>=', $from)
|
||||
->whereYear('server_date_published', '<', $until);
|
||||
|
||||
$documents = $select
|
||||
$documents = $select->orderBy('publish_id', 'asc')
|
||||
->get();
|
||||
|
||||
//$this->years = Dataset::select(DB::raw('YEAR(server_date_modified) as server_date_modified'))
|
||||
|
|
|
@ -187,7 +187,8 @@ class RequestController extends Controller
|
|||
$dataset = null;
|
||||
try {
|
||||
//$dataset = new Opus_Document($docId);
|
||||
$dataset = Dataset::findOrFail($dataId);
|
||||
//$dataset = Dataset::findOrFail($publishId);
|
||||
$dataset = Dataset::where('publish_id', '=', $dataId)->firstOrFail();
|
||||
} catch (ModelNotFoundException $ex) {
|
||||
throw new OaiModelException(
|
||||
'The value of the identifier argument is unknown or illegal in this repository.',
|
||||
|
@ -406,7 +407,7 @@ class RequestController extends Controller
|
|||
}
|
||||
|
||||
$totalIds = $finder->count();
|
||||
$reldocIds = $finder->pluck('id')->toArray();
|
||||
$reldocIds = $finder->orderBy('publish_id')->pluck('publish_id')->toArray();
|
||||
}
|
||||
|
||||
// handling of document ids
|
||||
|
@ -414,7 +415,8 @@ class RequestController extends Controller
|
|||
$workIds = array_splice($restIds, 0, $maxRecords);
|
||||
//foreach ($datasets as $dataset)
|
||||
foreach ($workIds as $dataId) {
|
||||
$dataset = Dataset::findOrFail($dataId);
|
||||
//$dataset = Dataset::findOrFail($dataId);
|
||||
$dataset = Dataset::where('publish_id', '=', $dataId)->firstOrFail();
|
||||
$this->createXmlRecord($dataset);
|
||||
}
|
||||
|
||||
|
@ -463,7 +465,7 @@ class RequestController extends Controller
|
|||
//$node = $this->xml->createElement('Rdr_Dataset');
|
||||
$domNode = $this->getDatasetXmlDomNode($dataset);
|
||||
// add frontdoor url
|
||||
$this->addLandingPageAttribute($domNode, $dataset->id);
|
||||
$this->addLandingPageAttribute($domNode, $dataset->publish_id);
|
||||
|
||||
// add access rights to element
|
||||
//$this->_addAccessRights($domNode, $dataset);
|
||||
|
|
Loading…
Add table
editor.link_modal.header
Reference in a new issue