- Licence.php (make name and language attributes fillable for LicenseController.php)
- LicencseController.php: select attribute part1 from languages - adaptions for oai_datacite.xslt, doi_datacite.xslt and datasetxml2oai-pmh.xslt: for showing correct rights identifier add adding open access for CC-BY-4.0 and CC-BY-SA-4.0 licenses
This commit is contained in:
parent
5c49f899e5
commit
a68b7b34cf
|
@ -32,7 +32,7 @@ class LicenseController extends Controller
|
|||
//$languages = Language::where('active', true)->pluck('part2_t');
|
||||
$languages = DB::table('languages')
|
||||
->where('active', true)
|
||||
->pluck('part2_t', 'part2_t');
|
||||
->pluck('part1', 'part1');
|
||||
|
||||
return view('settings.license.edit', compact('license', 'languages'));
|
||||
}
|
||||
|
|
|
@ -11,6 +11,7 @@ class License extends Model
|
|||
|
||||
protected $fillable = [
|
||||
'name_long',
|
||||
'name',
|
||||
'language',
|
||||
'link_licence',
|
||||
'link_logo',
|
||||
|
@ -19,6 +20,7 @@ class License extends Model
|
|||
'comment_internal',
|
||||
'mime_type',
|
||||
'sort_order',
|
||||
'language',
|
||||
'active',
|
||||
'pod_allowed'
|
||||
];
|
||||
|
|
|
@ -576,8 +576,8 @@
|
|||
<xsl:template match="Licence" mode="oai_dc">
|
||||
<dc:rights>
|
||||
<xsl:value-of select="@NameLong" />
|
||||
</dc:rights>
|
||||
<xsl:if test="@Name = 'CC BY' or @Name = 'CC BY-SA'">
|
||||
</dc:rights>
|
||||
<xsl:if test="@Name = 'CC-BY-4.0' or @Name = 'CC-BY-SA-4.0'">
|
||||
<dc:rights>
|
||||
<xsl:text>info:eu-repo/semantics/openAccess</xsl:text>
|
||||
</dc:rights>
|
||||
|
|
|
@ -370,6 +370,9 @@
|
|||
<xsl:template match="Licence" mode="oai_datacite"
|
||||
xmlns="http://datacite.org/schema/kernel-4">
|
||||
<rights>
|
||||
<xsl:attribute name="xml:lang">
|
||||
<xsl:value-of select="@Language" />
|
||||
</xsl:attribute>
|
||||
<xsl:if test="@LinkLicence != ''">
|
||||
<xsl:attribute name="rightsURI">
|
||||
<xsl:value-of select="@LinkLicence" />
|
||||
|
@ -382,11 +385,11 @@
|
|||
<xsl:text>SPDX</xsl:text>
|
||||
</xsl:attribute>
|
||||
<xsl:attribute name="rightsIdentifier">
|
||||
<xsl:text>CC-BY-NC-ND-4.0</xsl:text>
|
||||
<xsl:value-of select="@Name" />
|
||||
</xsl:attribute>
|
||||
<xsl:value-of select="@NameLong" />
|
||||
</rights>
|
||||
<xsl:if test="@Name = 'CC BY' or @Name = 'CC BY-SA'">
|
||||
<xsl:if test="@Name = 'CC-BY-4.0' or @Name = 'CC-BY-SA-4.0'">
|
||||
<rights>
|
||||
<xsl:attribute name="rightsURI">
|
||||
<xsl:text>info:eu-repo/semantics/openAccess</xsl:text>
|
||||
|
|
|
@ -373,6 +373,9 @@
|
|||
<xsl:template match="Licence" mode="oai_datacite"
|
||||
xmlns="http://datacite.org/schema/kernel-4">
|
||||
<rights>
|
||||
<xsl:attribute name="xml:lang">
|
||||
<xsl:value-of select="@Language" />
|
||||
</xsl:attribute>
|
||||
<xsl:if test="@LinkLicence != ''">
|
||||
<xsl:attribute name="rightsURI">
|
||||
<xsl:value-of select="@LinkLicence" />
|
||||
|
@ -385,11 +388,11 @@
|
|||
<xsl:text>SPDX</xsl:text>
|
||||
</xsl:attribute>
|
||||
<xsl:attribute name="rightsIdentifier">
|
||||
<xsl:text>CC-BY-NC-ND-4.0</xsl:text>
|
||||
<xsl:value-of select="@Name" />
|
||||
</xsl:attribute>
|
||||
<xsl:value-of select="@NameLong" />
|
||||
</rights>
|
||||
<xsl:if test="@Name = 'CC BY' or @Name = 'CC BY-SA'">
|
||||
<xsl:if test="@Name = 'CC-BY-4.0' or @Name = 'CC-BY-SA-4.0'">
|
||||
<rights>
|
||||
<xsl:attribute name="rightsURI">
|
||||
<xsl:text>info:eu-repo/semantics/openAccess</xsl:text>
|
||||
|
|
|
@ -8,6 +8,12 @@
|
|||
=> '--no language--']) !!}
|
||||
</div>
|
||||
|
||||
<div class="pure-u-1 pure-u-md-1-2 pure-div">
|
||||
{!! Form::label('name', 'Identifier') !!}
|
||||
{!! Form::text('name', null, ['class' => 'pure-u-23-24', 'placeholder'
|
||||
=> '--no identifier--']) !!}
|
||||
</div>
|
||||
|
||||
<div class="pure-u-1 pure-u-md-1-2 pure-div">
|
||||
{!! Form::label('language', 'Sprache') !!}
|
||||
<div class="select pure-u-23-24">
|
||||
|
|
Loading…
Reference in New Issue
Block a user