- npm updates

- show additional translated Series_information and TranslatedTitle
- changed info in home-view-component.vue
This commit is contained in:
Arno Kaimbacher 2022-01-17 09:31:10 +01:00
parent 3b44926ce1
commit 937b759544
5 changed files with 572 additions and 517 deletions

1039
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@ -60,7 +60,7 @@ createApp(app)
cookieDomain: undefined, cookieDomain: undefined,
// Tell Matomo the website domain so that clicks on these domains are not tracked as 'Outlinks' // Tell Matomo the website domain so that clicks on these domains are not tracked as 'Outlinks'
// Default: undefined, example: '*.example.com' // Default: undefined, example: '*.example.com'
domains: undefined, domains: "*.tethys.at",
preInitActions: [], preInitActions: [],
}) })
.use(router) .use(router)

View File

@ -100,6 +100,14 @@ export class DbDataset {
public project?: Project, public project?: Project,
) {} ) {}
public hasTranslatedTitle(): boolean {
if (this.titles.some((e) => e.type === TitleType.Translated)) {
return true;
} else {
return false;
}
}
public hasTranslatedAbstract(): boolean { public hasTranslatedAbstract(): boolean {
if (this.abstracts.some((e) => e.type === "Translated")) { if (this.abstracts.some((e) => e.type === "Translated")) {
return true; return true;
@ -109,7 +117,15 @@ export class DbDataset {
} }
public hasSeriesInformationAbstract(): boolean { public hasSeriesInformationAbstract(): boolean {
if (this.abstracts.some((e) => e.type === AbstractType.Series_information)) { if (this.abstracts.some((e) => e.type === AbstractType.Series_information && this.language == e.language)) {
return true;
} else {
return false;
}
}
public hasTranslatedSeriesInformationAbstract(): boolean {
if (this.abstracts.some((e) => e.type === AbstractType.Series_information && this.language != e.language)) {
return true; return true;
} else { } else {
return false; return false;
@ -160,6 +176,10 @@ export class DbDataset {
return this.titles.find((e) => e.type === TitleType.Main); return this.titles.find((e) => e.type === TitleType.Main);
} }
public get TranslatedTitle(): Nullable<Title> {
return this.titles.find((e) => e.type === TitleType.Translated);
}
public get MainAbstract(): Nullable<Abstract> { public get MainAbstract(): Nullable<Abstract> {
return this.abstracts.find((e) => e.type === AbstractType.Abstract); return this.abstracts.find((e) => e.type === AbstractType.Abstract);
} }
@ -169,7 +189,11 @@ export class DbDataset {
} }
public get SeriesInformationAbstract(): Nullable<Abstract> { public get SeriesInformationAbstract(): Nullable<Abstract> {
return this.abstracts.find((e) => e.type === AbstractType.Series_information); return this.abstracts.find((e) => e.type === AbstractType.Series_information && this.language == e.language);
}
public get TranslatedSeriesInformationAbstract(): Nullable<Abstract> {
return this.abstracts.find((e) => e.type === AbstractType.Series_information && this.language != e.language);
} }
public get MethodsAbstract(): Nullable<Abstract> { public get MethodsAbstract(): Nullable<Abstract> {

View File

@ -66,7 +66,14 @@
<div class="card record-elem"> <div class="card record-elem">
<div class="columns" v-if="dataset.hasOwnProperty('titles')"> <div class="columns" v-if="dataset.hasOwnProperty('titles')">
<div class="column is-3-desktop is-4-tablet label">Title/<br />title:</div> <div class="column is-3-desktop is-4-tablet label">Title/<br />title:</div>
<div class="column is-9-desktop is-8-tablet">{{ dataset.titles[0].value }}</div> <!-- <div class="column is-9-desktop is-8-tablet">{{ dataset.titles[0].value }}</div> -->
<div class="column is-9-desktop is-8-tablet">
<p>{{ dataset.MainTitle.value }}</p>
<br />
<p v-if="dataset.hasTranslatedTitle()">
{{ dataset.TranslatedTitle.value }}
</p>
</div>
</div> </div>
<div class="columns" v-if="dataset.hasOwnProperty('abstracts')"> <div class="columns" v-if="dataset.hasOwnProperty('abstracts')">
<div class="column is-3-desktop is-4-tablet label"> <div class="column is-3-desktop is-4-tablet label">
@ -84,7 +91,11 @@
<div class="columns" v-if="dataset.hasOwnProperty('abstracts')"> <div class="columns" v-if="dataset.hasOwnProperty('abstracts')">
<div class="column is-3-desktop is-4-tablet label">Serieninformation/<br />series information:</div> <div class="column is-3-desktop is-4-tablet label">Serieninformation/<br />series information:</div>
<div class="column is-9-desktop is-8-tablet" v-if="dataset.hasSeriesInformationAbstract()"> <div class="column is-9-desktop is-8-tablet" v-if="dataset.hasSeriesInformationAbstract()">
{{ dataset.SeriesInformationAbstract?.value }} <p>{{ dataset.SeriesInformationAbstract?.value }}</p>
<br />
<p v-if="dataset.hasTranslatedSeriesInformationAbstract()">
{{ dataset.TranslatedSeriesInformationAbstract?.value }}
</p>
</div> </div>
<div class="column is-9-desktop is-8-tablet" v-else>-</div> <div class="column is-9-desktop is-8-tablet" v-else>-</div>
</div> </div>

View File

@ -162,8 +162,9 @@
<h1 class="text-white">HABEN SIE FRAGEN?</h1> <h1 class="text-white">HABEN SIE FRAGEN?</h1>
<p class="text-white text center p-5"> <p class="text-white text center p-5">
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Quis ipsum suspendisse ultrices Tethys RDR ist ein Datenverlag der Geologischen Bundesanstalt (GBA), der ausschließlich an der GBA generierte geowissenschaftliche Forschungsdaten
gravida. Risus commodo viverra maecenas accumsan lacus vel facilisis. publiziert. Die Datenpublikationen können sowohl in deutscher, als auch in englischer Sprache publiziert werden. Durch die Bereitstellung der
Datenpublikation zusammen mit Metadaten nach standardisierten Schemata werden die Publikationen auffindbar und zitierbar.
</p> </p>
<div class="mx-auto my-5" style="width: 170px"> <div class="mx-auto my-5" style="width: 170px">