Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
DBRepo
Manage
Activity
Members
Labels
Plan
External wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Package registry
Model registry
Operate
Terraform modules
Analyze
Contributor analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
FAIR Data Austria DB Repository
DBRepo
Commits
4b761c54
Verified
Commit
4b761c54
authored
6 months ago
by
Martin Weise
Browse files
Options
Downloads
Patches
Plain Diff
Simplified interface
parent
c7a0d19c
No related branches found
No related tags found
1 merge request
!370
Fixed the test
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
dbrepo-ui/components/database/DatabaseCreate.vue
+26
-25
26 additions, 25 deletions
dbrepo-ui/components/database/DatabaseCreate.vue
dbrepo-ui/locales/en-US.json
+11
-7
11 additions, 7 deletions
dbrepo-ui/locales/en-US.json
with
37 additions
and
32 deletions
dbrepo-ui/components/database/DatabaseCreate.vue
+
26
−
25
View file @
4b761c54
...
@@ -54,30 +54,12 @@
...
@@ -54,30 +54,12 @@
</v-col>
</v-col>
</v-row>
</v-row>
<v-row>
<v-row>
<v-col
<v-col>
md=
"6"
>
<v-select
v-model=
"payload.is_public"
name=
"public"
:label=
"$t('pages.database.subpages.create.data.label')"
:hint=
"$t('pages.database.subpages.create.data.hint')"
persistent-hint
:variant=
"inputVariant"
:items=
"visibilityOptions"
item-title=
"name"
item-value=
"value"
:rules=
"[v => !!v || $t('validation.required')]"
return-object
required
>
</v-select>
</v-col>
<v-col
md=
"6"
>
<v-select
<v-select
v-model=
"
payload.is_schema_public
"
v-model=
"
mode
"
name=
"
schema-public
"
name=
"
mode
"
:label=
"$t('pages.database.subpages.create.
schema
.label')"
:label=
"$t('pages.database.subpages.create.
visibility
.label')"
:hint=
"$t('pages.database.subpages.create.
schema
.hint')"
:hint=
"$t('pages.database.subpages.create.
visibility
.hint')"
persistent-hint
persistent-hint
:variant=
"inputVariant"
:variant=
"inputVariant"
:items=
"visibilityOptions"
:items=
"visibilityOptions"
...
@@ -86,6 +68,19 @@
...
@@ -86,6 +68,19 @@
:rules=
"[v => !!v || $t('validation.required')]"
:rules=
"[v => !!v || $t('validation.required')]"
return-object
return-object
required
>
required
>
<
template
v-slot:append-inner
>
<v-tooltip
location=
"bottom"
>
<template
v-slot:activator=
"
{ props }">
<v-icon
v-bind=
"props"
icon=
"mdi-help-circle-outline"
/>
</
template
>
{{ mode.hint }}
</v-tooltip>
</template>
</v-select>
</v-select>
</v-col>
</v-col>
</v-row>
</v-row>
...
@@ -125,14 +120,17 @@ export default {
...
@@ -125,14 +120,17 @@ export default {
engines
:
[],
engines
:
[],
visibilityOptions
:
[
visibilityOptions
:
[
{
{
name
:
this
.
$t
(
'
toolbars.database.public
'
),
name
:
this
.
$t
(
'
pages.database.subpages.create.visibility.public.label
'
),
hint
:
this
.
$t
(
'
pages.database.subpages.create.visibility.public.hint
'
),
value
:
true
value
:
true
},
},
{
{
name
:
this
.
$t
(
'
toolbars.database.private
'
),
name
:
this
.
$t
(
'
pages.database.subpages.create.visibility.private.label
'
),
hint
:
this
.
$t
(
'
pages.database.subpages.create.visibility.private.hint
'
),
value
:
false
value
:
false
}
}
],
],
mode
:
true
,
payload
:
{
payload
:
{
name
:
null
,
name
:
null
,
is_public
:
true
,
is_public
:
true
,
...
@@ -151,6 +149,7 @@ export default {
...
@@ -151,6 +149,7 @@ export default {
}
}
},
},
mounted
()
{
mounted
()
{
this
.
mode
=
this
.
visibilityOptions
[
0
]
this
.
fetchContainers
()
this
.
fetchContainers
()
},
},
methods
:
{
methods
:
{
...
@@ -186,6 +185,8 @@ export default {
...
@@ -186,6 +185,8 @@ export default {
create
()
{
create
()
{
this
.
loading
=
true
this
.
loading
=
true
this
.
payload
.
container_id
=
this
.
engine
.
id
this
.
payload
.
container_id
=
this
.
engine
.
id
this
.
payload
.
is_public
=
this
.
mode
.
value
this
.
payload
.
is_schema_public
=
this
.
mode
.
value
const
databaseService
=
useDatabaseService
()
const
databaseService
=
useDatabaseService
()
databaseService
.
create
(
this
.
payload
)
databaseService
.
create
(
this
.
payload
)
.
then
(
async
(
database
)
=>
{
.
then
(
async
(
database
)
=>
{
...
...
This diff is collapsed.
Click to expand it.
dbrepo-ui/locales/en-US.json
+
11
−
7
View file @
4b761c54
...
@@ -653,13 +653,17 @@
...
@@ -653,13 +653,17 @@
"label"
:
"Engine"
,
"label"
:
"Engine"
,
"hint"
:
"Required"
"hint"
:
"Required"
},
},
"data"
:
{
"visibility"
:
{
"label"
:
"Data Visibility"
,
"label"
:
"Visibility"
,
"hint"
:
"Required"
"hint"
:
"Required"
,
"public"
:
{
"label"
:
"Public"
,
"hint"
:
"Everything is visible to the public, e.g. to publish data used in a open-access paper. You can later update the visibility of data."
},
},
"schema"
:
{
"private"
:
{
"label"
:
"Schema Visibility"
,
"label"
:
"Private"
,
"hint"
:
"Required"
"hint"
:
"Nothing is visible to anyone without dedicated read-access, e.g. to work on a dataset. You can later update the visibility of data."
}
},
},
"submit"
:
{
"submit"
:
{
"text"
:
"Create"
"text"
:
"Create"
...
...
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