41
41
</template >
42
42
</i18n >
43
43
</div >
44
- <div class =" mb-3" >
45
- <strong >{{ $t('data.info.descriptors.category') }}</strong >
46
-   ;
47
- <span >{{ category }}</span >
48
- </div >
49
44
<div class =" mb-3" >
50
45
<strong >{{ $t('data.info.descriptors.keywords') }}</strong >
51
46
  ;
62
57
<div >
63
58
<strong >{{ $t('data.info.descriptors.links') }}</strong >
64
59
<ul >
65
- <li v-if =" wafDataset" >
66
- <a :href =" datasetWafURL" target =" _blank" >
60
+ <li >
61
+ <a :href =" firstwafURL" target =" _blank" >
62
+ {{ $t('data.info.links.waf') }}
63
+ <v-icon x-small >mdi-open-in-new</v-icon >
64
+ </a >
65
+ </li >
66
+ <li v-if =" hasSecondWAF" >
67
+ <a :href =" secondwafURL" target =" _blank" >
67
68
{{ $t('data.info.links.waf') }}
68
69
<v-icon x-small >mdi-open-in-new</v-icon >
69
70
</a >
@@ -117,10 +118,16 @@ export default {
117
118
return {
118
119
abstract: null ,
119
120
aliases: {
120
- broadband: ' broad-band' ,
121
- multiband: ' multi-band' ,
122
- umkehrn14_1: ' umkehrn14_1.0' ,
123
- umkehrn14_2: ' umkehrn14_2.0' ,
121
+ broadband: ' Broad-band' ,
122
+ multiband: ' Multi-band' ,
123
+ umkehrn14_1: ' UmkehrN14_1.0' ,
124
+ umkehrn14_2: ' UmkehrN14_2.0' ,
125
+ totalozone: ' TotalOzone' ,
126
+ totalozoneobs: ' TotalOzoneObs' ,
127
+ lidar: ' Lidar' ,
128
+ ozonesonde: ' OzoneSonde' ,
129
+ rocketsonde: ' RocketSonde' ,
130
+ spectral: ' Spectral' ,
124
131
},
125
132
category: null ,
126
133
collectionItem: null ,
@@ -136,7 +143,8 @@ export default {
136
143
stations: [],
137
144
title: null ,
138
145
uriDatasetDef: null ,
139
- wafDataset: null ,
146
+ // wafDataset: null,
147
+ wafURL: [],
140
148
}
141
149
},
142
150
head () {
@@ -159,10 +167,19 @@ export default {
159
167
doiURL () {
160
168
return ` http://dx.doi.org/${ this .doi } `
161
169
},
170
+ firstwafURL () {
171
+ return this .wafURL [0 ]
172
+ },
173
+ secondwafURL () {
174
+ return this .wafURL [1 ]
175
+ },
162
176
datasetWafURL () {
163
177
const archivePath = this .$config .WOUDC_UI_WAF_URL + ' /Archive-NewFormat'
164
178
return ` ${ archivePath} /${ this .wafDataset } `
165
179
},
180
+ hasSecondWAF : function () {
181
+ return this .wafURL .length > 1
182
+ },
166
183
},
167
184
mounted () {
168
185
this .init ()
@@ -179,22 +196,26 @@ export default {
179
196
} else {
180
197
this .dataset = this .$route .params .id
181
198
}
199
+
182
200
const discoveryMetadataURL =
183
201
this .$config .WOUDC_UI_API_URL + ' /collections/discovery_metadata/items'
184
- this .uriDatasetDef = discoveryMetadataURL + ' ?identifier=' + this .dataset
202
+
203
+ this .uriDatasetDef = ` ${ discoveryMetadataURL} /${ this .dataset } ?f=json`
204
+
185
205
const response = await woudcClient .get (this .uriDatasetDef )
186
- this .collectionItem = response . data . features [ 0 ]. properties
206
+ this .collectionItem = response
187
207
188
- this .dataset_id = this .collectionItem .identifier
189
- this .title = this .collectionItem [` title_${ this .$i18n .locale } ` ]
190
- this .abstract = this .collectionItem [` abstract_${ this .$i18n .locale } ` ]
191
- this .doi = this .collectionItem .doi
192
- this .dateFrom = this .collectionItem .temporal_begin
193
- this .dateTo = this .collectionItem .temporal_end
194
- this .category = this .collectionItem .topic_category
195
- this .keywords = this .collectionItem [` keywords_${ this .$i18n .locale } ` ]
196
- if (this .dataset !== ' uv_index_hourly' ) {
197
- this .wafDataset = this .collectionItem .waf [` label_${ this .$i18n .locale } ` ]
208
+ this .dataset_id = this .collectionItem .data .id
209
+ this .title = this .collectionItem .data .properties .title
210
+ this .abstract = this .collectionItem .data .properties .description
211
+ this .doi = this .collectionItem .data .properties .externalIds [0 ].value
212
+ this .dateFrom = this .collectionItem .data .time .interval [0 ]
213
+ this .dateTo = this .collectionItem .data .time .interval [1 ]
214
+ this .keywords = this .collectionItem .data .properties .keywords
215
+ for (const item of this .collectionItem .data .links ) {
216
+ if (item .title == ' Web Accessible Folder (WAF)' ) {
217
+ this .wafURL .push (item .href )
218
+ }
198
219
}
199
220
},
200
221
stationText (station ) {
0 commit comments