File tree Expand file tree Collapse file tree 5 files changed +9
-45
lines changed
pages/datasets/[datasetid] Expand file tree Collapse file tree 5 files changed +9
-45
lines changed Original file line number Diff line number Diff line change @@ -163,11 +163,11 @@ export default defineNuxtConfig({
163163 ? "https://staging.fairhub.io/local-login"
164164 : "https://fairhub.io/local-login" ,
165165 } ,
166- STUDY_RELEASE_TIMESTAMP :
167- process . env . NUXT_SITE_ENV === "dev" ||
168- process . env . NUXT_SITE_ENV === "staging"
169- ? "1763157600" // Mon Nov 11 2025 14:00:00 GMT-0800 (Pacific Standard Time)
170- : "1763168400" , // Mon Nov 11 2025 17:00:00 GMT-0800 (Pacific Standard Time)
166+ // STUDY_RELEASE_TIMESTAMP:
167+ // process.env.NUXT_SITE_ENV === "dev" ||
168+ // process.env.NUXT_SITE_ENV === "staging"
169+ // ? "1763157600" // Mon Nov 11 2025 14:00:00 GMT-0800 (Pacific Standard Time)
170+ // : "1763168400", // Mon Nov 11 2025 17:00:00 GMT-0800 (Pacific Standard Time)
171171 UMAMI_SHARE_URL :
172172 process . env . NUXT_SITE_ENV === "dev" ||
173173 process . env . NUXT_SITE_ENV === "staging"
Original file line number Diff line number Diff line change @@ -157,7 +157,7 @@ const allChecked = computed(() =>
157157 in order to receive the dataset due to the size of the
158158 AI-READI dataset. Please
159159 <NuxtLink
160- to =" https://docs.aireadi.org/docs/2 /preliminary/azure_storage/azure"
160+ to =" https://docs.aireadi.org/docs/3 /preliminary/azure_storage/azure"
161161 >review our documentation</NuxtLink
162162 >
163163 to set this up.
Original file line number Diff line number Diff line change @@ -643,7 +643,7 @@ const onTabChange = () => {
643643
644644 <n-flex >
645645 <NuxtLink
646- to =" http://b21ai-dqd.fnbqhhfhbwfnd5h0. westus2.azurecontainer.io:3838/"
646+ to =" http://b21ai-dqd.westus2.azurecontainer.io:3838/"
647647 target =" _blank"
648648 >
649649 <n-button size =" large" type =" info" secondary class =" my-3" >
Original file line number Diff line number Diff line change 11export default defineEventHandler ( async ( event ) => {
22 const { datasetid } = event . context . params as { datasetid : string } ;
33
4- const config = useRuntimeConfig ( ) ;
5- const currentTime = Math . round ( Date . now ( ) / 1000 ) ;
6- const studyReleaseTimestamp = Number ( config . public . STUDY_RELEASE_TIMESTAMP ) ;
7-
8- if (
9- currentTime < studyReleaseTimestamp &&
10- datasetid !== "2" &&
11- datasetid !== "1"
12- ) {
13- throw createError ( {
14- message : `Dataset ${ datasetid } not found` ,
15- statusCode : 404 ,
16- } ) ;
17- }
18-
194 const publishedDataset = await prisma . published_dataset . findUnique ( {
205 where : {
216 id : datasetid ,
@@ -69,7 +54,7 @@ export default defineEventHandler(async (event) => {
6954 } ,
7055 } ) ;
7156
72- let versions : VersionArray = relatedDatasets . map ( ( relatedDataset ) => {
57+ const versions : VersionArray = relatedDatasets . map ( ( relatedDataset ) => {
7358 return {
7459 id : Number ( relatedDataset . id ) . toString ( ) ,
7560 title : relatedDataset . version_title ,
@@ -78,12 +63,6 @@ export default defineEventHandler(async (event) => {
7863 } ;
7964 } ) ;
8065
81- if ( currentTime < studyReleaseTimestamp ) {
82- versions = versions . filter (
83- ( version ) => version . id === "2" || version . id === "1" ,
84- ) ;
85- }
86-
8766 const dataset : Dataset = {
8867 id : datasetId ,
8968 title : publishedDataset . title ,
Original file line number Diff line number Diff line change 11export default defineEventHandler ( async ( _event ) => {
2- const config = useRuntimeConfig ( ) ;
3- const currentTime = Math . round ( Date . now ( ) / 1000 ) ;
4- const studyReleaseTimestamp = Number ( config . public . STUDY_RELEASE_TIMESTAMP ) ;
5-
62 const publishedDatasets = await prisma . published_dataset . findMany ( {
7- // distinct: ["dataset_id"],
3+ distinct : [ "dataset_id" ] ,
84 orderBy : [ { created_at : "desc" } ] ,
95 } ) ;
106
@@ -18,17 +14,6 @@ export default defineEventHandler(async (_event) => {
1814 for ( const dataset of publishedDatasets ) {
1915 const datasetId = Number ( dataset . id ) . toString ( ) ;
2016
21- // Filter based on timestamp: dataset 2 if before timestamp, datasets 3 and 4 if after
22- if ( currentTime < studyReleaseTimestamp ) {
23- // Only return dataset 2 if currentTime < timestamp
24- if ( datasetId !== "2" ) {
25- continue ;
26- }
27- } else if ( datasetId !== "3" && datasetId !== "4" ) {
28- // Only return datasets 3 and 4 if currentTime >= timestamp
29- continue ;
30- }
31-
3217 const datasetAdditionalData = dataset . data as any ;
3318 const datasetCreatedAt : bigint = BigInt ( dataset . created_at ) ;
3419
You can’t perform that action at this time.
0 commit comments