Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
E
ESAP GUI
Manage
Activity
Members
Labels
Plan
Jira
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
ASTRON SDC
ESCAPE WP5
ESAP GUI
Commits
33364c8a
Commit
33364c8a
authored
4 years ago
by
Zheng Meyer
Browse files
Options
Downloads
Patches
Plain Diff
render VO results properly
parent
f13b4f5a
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/components/query/ASTRONVOResults.js
+7
-8
7 additions, 8 deletions
src/components/query/ASTRONVOResults.js
src/components/query/QueryCatalogs.js
+1
-48
1 addition, 48 deletions
src/components/query/QueryCatalogs.js
with
8 additions
and
56 deletions
src/components/query/ASTRONVOResults.js
+
7
−
8
View file @
33364c8a
...
...
@@ -17,17 +17,19 @@ export default function ASTRONVOResults({ catalog }) {
<InputGroup.Checkbox />
</InputGroup>
</th> */
}
<
th
>
Title
<
/th
>
<
th
>
Collection
<
/th
>
<
th
>
RA
<
/th
>
<
th
>
Dec
<
/th
>
<
th
>
fov
<
/th
>
<
th
>
Data
Product
Type
<
/th
>
<
th
>
Calibration
Level
<
/th
>
<
th
>
Size
<
/th
>
<
th
>
Link
to
data
<
/th
>
<
/tr
>
<
/thead
>
<
tbody
>
{
queryMap
.
get
(
catalog
).
results
.
query_results
.
map
((
result
)
=>
{
let
size
=
Number
((
result
.
size
/
1024
).
toFixed
(
1
));
return
(
<
tr
key
=
{
result
.
result
}
>
{
/* <th>
...
...
@@ -35,19 +37,16 @@ export default function ASTRONVOResults({ catalog }) {
<InputGroup.Checkbox />
</InputGroup>
</th> */
}
<
td
>
{
result
.
title
}
<
/td
>
<
td
>
{
result
.
obs_collection
}
<
/td
>
<
td
>
{
result
.
ra
}
<
/td
>
<
td
>
{
result
.
dec
}
<
/td
>
<
td
>
{
result
.
fov
}
<
/td
>
<
td
>
{
result
.
dataproduct_type
}
<
/td
>
<
td
>
{
result
.
calibration_level
}
<
/td
>
<
td
>
{
size
}
MB
<
/td
>
<
td
>
<
a
href
=
{
result
.
url
}
target
=
"
_blank
"
rel
=
"
noopener noreferrer
"
>
View
data
<
a
href
=
{
result
.
url
}
rel
=
"
noopener noreferrer
"
download
>
Download
<
/a
>
<
/td
>
<
/tr
>
...
...
This diff is collapsed.
Click to expand it.
src/components/query/QueryCatalogs.js
+
1
−
48
View file @
33364c8a
...
...
@@ -25,54 +25,6 @@ export default function QueryCatalogs() {
let
gui
=
config
.
query_schema
.
name
;
const
queries
=
parseQueryForm
(
gui
,
formData
,
catalogs
);
// queries.forEach((query) => {
// let url =
// api_host + "query/create-query/?" + "archive_uri=" + query.catalog;
// axios.get(url).then((response) => {
// queryMap.set(query.catalog, {
// catalog: query.catalog,
// dataset_uri: response.data.query_input[0].dataset,
// access_url: response.data.query_input[0].service_url,
// catalogquery: response.data.query_input[0].query,
// status: "fetching",
// results: null,
// });
// console.log("CatalogQuery:", queryMap.get(query.catalog).catalogquery);
// let queryUrl =
// api_host +
// "query/run-query/?" +
// "dataset_uri=" +
// queryMap.get(query.catalog).dataset_uri +
// "&access_url=" +
// queryMap.get(query.catalog).access_url +
// "&query=" +
// queryMap.get(query.catalog).catalogquery;
// axios
// .get(queryUrl)
// .then((queryResponse) => {
// queryMap.set(query.catalog, {
// catalog: query.catalog,
// dataset_uri: response.data.query_input[0].dataset,
// access_url: response.data.query_input[0].service_url,
// catalogquery: response.data.query_input[0].query,
// status: "fetched",
// results: queryResponse.data,
// });
// })
// .catch(() => {
// queryMap.set(query.catalog, {
// catalog: query.catalog,
// dataset_uri: response.data.query_input[0].dataset,
// access_url: response.data.query_input[0].service_url,
// catalogquery: response.data.query_input[0].query,
// status: "error",
// results: null,
// });
// });
// });
// });
// Ideally query for each catalog is sent to ESAP API Gateway, and query results is returned
// This is under development in the backend at the moment
queries
.
forEach
((
query
)
=>
{
...
...
@@ -135,6 +87,7 @@ export default function QueryCatalogs() {
><
/Form
>
{
Array
.
from
(
queryMap
.
keys
()).
map
((
catalog
)
=>
{
const
details
=
queryMap
.
get
(
catalog
);
console
.
log
(
"
Details:
"
,
details
);
console
.
log
(
"
Results:
"
,
details
.
results
);
return
(
<
div
key
=
{
catalog
}
className
=
"
mt-3
"
>
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment