postgres tables migrated from sqlite3
user table is empty in the beginning
react register chuanshuo
postgres auth_user table now has chuanshuo, with is_superuser=false and is_stuff=false
login with chuanshuo successfully
post an album successfully
postgres album table now contains 1 album
react displays albums
failed to login django admin with chuanshuo
postgres alter auth_user table, set is_superuser=true and is_stuff=true for chanshuo
login django admin successfully with chuanshuo
django admin has 1 album on file
#powershell create superuser bob
PS C:\Users\bob\django\project1> python manage.py createsuperuser
Username (leave blank to use 'bob'): bob
Email address: chuanshuoge2@gmail.com
Password:
Password (again):
Superuser created successfully.
postgres auth_user table has 2 superusers
login as bob and post an album
postgres album table has 2 records now
reference:
https://docs.djangoproject.com/en/1.8/intro/tutorial02/
No comments:
Post a Comment