Skip to content
Snippets Groups Projects
Commit ac0b4a45 authored by David Mendez's avatar David Mendez
Browse files

Load privacy notice from backend

parent fec89ad7
No related branches found
No related tags found
1 merge request!41Load privacy notice from backend
......@@ -7,6 +7,7 @@
This statement explains how we use cookies and your IP address on the
EUbOPEN website.
</p>
<p class="text-justify"><b>Last updated:</b> {{ lastUpdated }}</p>
<h2 class="font-weight-light">How we use cookies</h2>
<br />
......@@ -53,6 +54,11 @@
<script>
export default {
data() {
return {
lastUpdated: '28 October 2021',
}
},
head() {
const titleText = `Cookie Statement`
const descriptionText = 'Read the cookie statement for the EUbOPEN Portal.'
......
<template>
<div>
<h1 class="font-weight-light">Privacy Notice</h1>
<v-divider />
<br />
<p class="text-justify">
Click <a href="/DraftPrivacyNotice.pdf">here</a> to download the DRAFT of
the privacy notice. Ths draft is generated by the EBI Data Protection
Engine (DPE). Once we agree on a final version, this page will be
generated with the data generated by the DPE.
</p>
<p class="text-justify">
The PDF file was generated by printing the current record in the DPE.
</p>
<v-skeleton-loader v-if="loading" type="paragraph@3"></v-skeleton-loader>
<template v-else>
<br />
<b>Last updated: {{ lastUpdated }} </b>
<br /><br />
<div v-html="body"></div>
</template>
</div>
</template>
<script>
import RequestNotifications from '@/web-components-submodule/utils/RequestNotifications.js'
import ESProxyService from '~/web-components-submodule/services/ESProxyService.js'
export default {
data() {
return {
loading: true,
body: '',
lastUpdated: '',
}
},
head() {
const titleText = `Privacy Notice`
const descriptionText = 'Read the privacy notice for the EUbOPEN Portal.'
......@@ -53,6 +57,23 @@ export default {
],
}
},
mounted() {
const privacyNoticePath = '/eubopen/miscellaneous/privacy_notice'
ESProxyService.getGenericData(privacyNoticePath)
.then((response) => {
this.lastUpdated = response.data.nodes[0].node.changed
this.body = response.data.nodes[0].node.body
this.loading = false
})
.catch((error) => {
RequestNotifications.dispatchRequestErrorNotification(
error,
this.$store.dispatch,
`There was an error while loading the privacy notice data!`
)
})
},
}
</script>
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment