django-mongoengine icon indicating copy to clipboard operation
django-mongoengine copied to clipboard

Superuser has no permission

Open ShipraShalini opened this issue 8 years ago • 8 comments

When I login to django admin with super user I get the following message.

screen shot 2016-08-11 at 6 46 47 pm

The user_permissions array is also empty in mongodb.

{ "_id": ObjectId("57dc5db686w5c77e351e2e1c"), "_cls": "User.Member", "email": "[email protected]", "password": "pbkdf2_sha256$24C000$7vNWGxjVxbr$LvauNaXnjlwPrGdG+3b1Cz04vpoW7f0kxV/0nkW6Abg=", "is_active": true, "is_superuser": true, "last_login": ISODate("2016-08-11T12:03:58.895Z"), "date_joined": ISODate("2016-08-11T11:12:53.376Z"), "user_permissions": [], "is_staff": true, "username": "djadmin" }

Is there anyway to fix this?

ShipraShalini avatar Aug 11 '16 13:08 ShipraShalini

may be you don't configured any apps? Take a look at example app.

Btw, admin part of the project is not ready yet, if you want to use it: be prepared to fix everything you need.

last-partizan avatar Aug 11 '16 13:08 last-partizan

I have configured apps according to the example app.

I also noticed that there's no permissions collection in mongodb. The code seems fine, I have no clue why it's not being created.

ShipraShalini avatar Aug 11 '16 16:08 ShipraShalini

I have no clue too.

last-partizan avatar Aug 11 '16 17:08 last-partizan

hi @ShipraShalini, same problem here, you still have no clue ?

maxperei avatar Apr 23 '17 19:04 maxperei

Hi to all! This problem is still present. Is someone knows how to fix it?

Lucas63 avatar Sep 09 '17 22:09 Lucas63

Hi, check it yourself. Last time i tried to use admin it was working.

last-partizan avatar Sep 10 '17 05:09 last-partizan

@last-partizan, i have configure my app as in example provided in this repostirory. I have created superuser successfully, but when i login in admin panel, i see that i have no permissions(like on screen above)

Lucas63 avatar Sep 10 '17 14:09 Lucas63

@Lucas63 are you sure you using correct module in urls? in the example we're using mongoadmin, which is different from default django.contrib.admin module

last-partizan avatar Sep 12 '17 07:09 last-partizan