Fix access grant and revoke workflow actions
Signed-off-by: Roberto Rosario <roberto.rosario.gonzalez@gmail.com>
This commit is contained in:
@@ -36,7 +36,7 @@ class ModelPermission(object):
|
||||
|
||||
if as_content_type:
|
||||
content_type_dictionary = ContentType.objects.get_for_models(
|
||||
models=cls._registry.keys()
|
||||
*cls._registry.keys()
|
||||
)
|
||||
content_type_ids = [
|
||||
content_type.pk for content_type in content_type_dictionary.values()
|
||||
|
||||
12
mayan/apps/acls/tests/test_classes.py
Normal file
12
mayan/apps/acls/tests/test_classes.py
Normal file
@@ -0,0 +1,12 @@
|
||||
from __future__ import absolute_import, unicode_literals
|
||||
|
||||
from mayan.apps.common.tests import BaseTestCase
|
||||
|
||||
from ..classes import ModelPermission
|
||||
|
||||
|
||||
class ModelpermissionTestCase(BaseTestCase):
|
||||
def test_model_permission_get_classes_as_content_type(self):
|
||||
self.assertNotEqual(
|
||||
ModelPermission.get_classes(as_content_type=True).count(), 0
|
||||
)
|
||||
Reference in New Issue
Block a user