Skip to content

Commit

Permalink
Merge pull request #245 from EGA-archive/develop
Browse files Browse the repository at this point in the history
adding minor fixes
  • Loading branch information
costero-e authored Nov 9, 2023
2 parents ff0a481 + 89f09c0 commit 39b93be
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 9 deletions.
3 changes: 1 addition & 2 deletions permissions/controlled_datasets.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
app-user3:
- CINECA_synthetic_cohort_EUROPE_UK1
- AV_Dataset
hola:
- CINECA_synthetic_cohort_EUROPE_UK1
hola: []
12 changes: 9 additions & 3 deletions permissions/permissions-ui/bash/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -117,8 +117,6 @@ def load_controlled_datasets(user):

return list_controlled_datasets



def bash_view(request):
template = "home.html"
form =BamForm()
Expand All @@ -142,6 +140,8 @@ def public_view(request):
context={'bash_out': bash_out, 'datasets': datasets}
if request.method == 'POST':
answer = request.POST.getlist('list', False)
if answer == False:
answer = []
add_public_datasets(answer)
context = {
'answer': answer,
Expand All @@ -156,6 +156,8 @@ def registered_view(request):
context={'bash_out': bash_out, 'datasets': datasets}
if request.method == 'POST':
answer = request.POST.getlist('list', False)
if answer == False:
answer = []
add_registered_datasets(answer)
context = {
'answer': answer,
Expand All @@ -182,7 +184,11 @@ def controlled_view(request):
if request.method == 'POST':
user = request.POST.getlist('users', False)
datasets_list = request.POST.getlist('list', False)
add_controlled_datasets(user, datasets_list)
if datasets_list == False:
datasets_list = []
add_controlled_datasets(user, datasets_list)
else:
add_controlled_datasets(user, datasets_list)
context = {
'answer': user, 'datasets_list': datasets_list
}
Expand Down
2 changes: 1 addition & 1 deletion permissions/public_datasets.yml
Original file line number Diff line number Diff line change
@@ -1 +1 @@
public_datasets: false
public_datasets: []
4 changes: 1 addition & 3 deletions permissions/registered_datasets.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
registered_datasets:
- CINECA_synthetic_cohort_EUROPE_UK1
- AV_Dataset
registered_datasets: []

0 comments on commit 39b93be

Please sign in to comment.