mirror of
https://github.com/Cian-H/invenio-theme-iform.git
synced 2026-08-08 21:23:22 +01:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
b27d54b6f0 | ||
|
|
f81ca88835 | ||
|
|
39c19238dd | ||
|
|
3f14a3ada4 |
+47
@@ -0,0 +1,47 @@
|
|||||||
|
// This file is part of React-Invenio-Deposit
|
||||||
|
// Copyright (C) 2020 CERN.
|
||||||
|
// Copyright (C) 2020 Northwestern University.
|
||||||
|
// Copyright (C) 2021 Graz University of Technology.
|
||||||
|
//
|
||||||
|
// React-Invenio-Deposit is free software; you can redistribute it and/or modify it
|
||||||
|
// under the terms of the MIT License; see LICENSE file for more details.
|
||||||
|
|
||||||
|
import React, { Component } from 'react';
|
||||||
|
import PropTypes from 'prop-types';
|
||||||
|
|
||||||
|
import { FieldLabel, TextField } from 'react-invenio-forms';
|
||||||
|
|
||||||
|
export class PublisherField extends Component {
|
||||||
|
render() {
|
||||||
|
const { fieldPath, label, labelIcon, placeholder, required } = this.props;
|
||||||
|
|
||||||
|
return (
|
||||||
|
<TextField
|
||||||
|
fieldPath={fieldPath}
|
||||||
|
helpText={
|
||||||
|
'The publisher is used to formulate the citation, if you are plannig to mint a new DOI this publisher will be cited.'
|
||||||
|
}
|
||||||
|
label={
|
||||||
|
<FieldLabel htmlFor={fieldPath} icon={labelIcon} label={label} />
|
||||||
|
}
|
||||||
|
placeholder={placeholder}
|
||||||
|
required={required}
|
||||||
|
/>
|
||||||
|
);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
PublisherField.propTypes = {
|
||||||
|
fieldPath: PropTypes.string.isRequired,
|
||||||
|
label: PropTypes.string,
|
||||||
|
labelIcon: PropTypes.string,
|
||||||
|
placeholder: PropTypes.string,
|
||||||
|
required: PropTypes.bool,
|
||||||
|
};
|
||||||
|
|
||||||
|
PublisherField.defaultProps = {
|
||||||
|
fieldPath: 'metadata.publisher',
|
||||||
|
label: 'Publisher',
|
||||||
|
labelIcon: 'building outline',
|
||||||
|
placeholder: 'Enter publisher name',
|
||||||
|
};
|
||||||
+2
-2
@@ -33,7 +33,6 @@ import {
|
|||||||
LanguagesField,
|
LanguagesField,
|
||||||
PublishButton,
|
PublishButton,
|
||||||
PublicationDateField,
|
PublicationDateField,
|
||||||
PublisherField,
|
|
||||||
ResourceTypeField,
|
ResourceTypeField,
|
||||||
SaveButton,
|
SaveButton,
|
||||||
SubjectsField,
|
SubjectsField,
|
||||||
@@ -44,6 +43,7 @@ import {
|
|||||||
} from "react-invenio-deposit";
|
} from "react-invenio-deposit";
|
||||||
import { AccordionField } from "react-invenio-forms";
|
import { AccordionField } from "react-invenio-forms";
|
||||||
import { DoiMint } from "./DoiMint";
|
import { DoiMint } from "./DoiMint";
|
||||||
|
import { PublisherField } from "./PublisherField";
|
||||||
|
|
||||||
export class RDMDepositForm extends Component {
|
export class RDMDepositForm extends Component {
|
||||||
constructor(props) {
|
constructor(props) {
|
||||||
@@ -448,7 +448,7 @@ export class RDMDepositForm extends Component {
|
|||||||
/>
|
/>
|
||||||
<DatesField options={this.vocabularies.metadata.dates} />
|
<DatesField options={this.vocabularies.metadata.dates} />
|
||||||
<VersionField />
|
<VersionField />
|
||||||
<PublisherField />
|
<PublisherField required/>
|
||||||
<br />
|
<br />
|
||||||
</AccordionField>
|
</AccordionField>
|
||||||
{/**TODO: uncomment to use FundingField*/}
|
{/**TODO: uncomment to use FundingField*/}
|
||||||
|
|||||||
@@ -29,6 +29,10 @@
|
|||||||
|
|
||||||
<h2>{{_ ("Repository")}}</h2>
|
<h2>{{_ ("Repository")}}</h2>
|
||||||
<p class="bodytext">
|
<p class="bodytext">
|
||||||
|
<a href="https://tu-graz-library.github.io/docs-repository" title="Repository documentation" target="_blank">
|
||||||
|
{{_ ("Documentation")}} <i class="external alternate icon"></i>
|
||||||
|
</a>
|
||||||
|
<br>
|
||||||
<!-- <a href="{{ url_for('invenio_theme_tugraz.comingsoon') }}">
|
<!-- <a href="{{ url_for('invenio_theme_tugraz.comingsoon') }}">
|
||||||
{{_ ("Impressum")}}<i class="angle right icon"></i>
|
{{_ ("Impressum")}}<i class="angle right icon"></i>
|
||||||
</a>
|
</a>
|
||||||
|
|||||||
@@ -98,7 +98,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
{%- endblock record_footer -%}
|
{%- endblock record_footer -%}
|
||||||
{%- block jump -%}
|
<!-- {%- block jump -%}
|
||||||
<div class="ui grid">
|
<div class="ui grid">
|
||||||
<div class="centered row" id="jump-btn">
|
<div class="centered row" id="jump-btn">
|
||||||
<a style="cursor: pointer;">
|
<a style="cursor: pointer;">
|
||||||
@@ -107,7 +107,7 @@
|
|||||||
</a>
|
</a>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
{%- endblock jump -%}
|
{%- endblock jump -%} -->
|
||||||
{%- endblock record_body %}
|
{%- endblock record_body %}
|
||||||
</div>
|
</div>
|
||||||
<div class="five wide column">
|
<div class="five wide column">
|
||||||
|
|||||||
@@ -12,4 +12,4 @@ This file is imported by ``invenio_theme_tugraz.__init__``,
|
|||||||
and parsed by ``setup.py``.
|
and parsed by ``setup.py``.
|
||||||
"""
|
"""
|
||||||
|
|
||||||
__version__ = "1.9.4"
|
__version__ = "1.9.6"
|
||||||
|
|||||||
Reference in New Issue
Block a user