Skip to content

Commit

Permalink
fix: media editor adv unable to view/use folders (#893)
Browse files Browse the repository at this point in the history
  • Loading branch information
wesleyboar authored Nov 11, 2024
1 parent 5d9d06a commit d323b8b
Showing 1 changed file with 7 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,13 @@ def set_group_perms():
content_type = ContentType.objects.get(app_label='filer', model=model_name)
group.permissions.add( Permission.objects.get(name='Can delete file', content_type=content_type) )

model_name = 'Folder'.lower().replace(' ', '')
content_type = ContentType.objects.get(app_label='filer', model=model_name)
group.permissions.add( Permission.objects.get(name='Can use directory listing', content_type=content_type) )
model_name = 'Folder'.lower().replace(' ', '')
content_type = ContentType.objects.get(app_label='filer', model=model_name)
group.permissions.add( Permission.objects.get(name='Can view Folder', content_type=content_type) )

model_name = 'image'.lower().replace(' ', '')
content_type = ContentType.objects.get(app_label='filer', model=model_name)
group.permissions.add( Permission.objects.get(name='Can change image', content_type=content_type) )
Expand Down

0 comments on commit d323b8b

Please sign in to comment.