MyTetra Share
Делитесь знаниями!
5. manage admin application
Время создания: 07.09.2017 20:27
Раздел: Python - Django - __Порядок работы с проектом
Запись: xintrea/mytetra_db_mcold/master/base/1504805259nddnhtovoh/text.html на

If you already have a superuser or have forgotten it, you can always create one using the following code −

$ python createsuperuser

Now to start the Admin Interface, we need to make sure we have configured a URL for our admin interface. Open the myproject/ and you should have something like −

from django.conf.urls import patterns, include, url

from django.contrib import admin


urlpatterns = patterns('',

# Examples:

# url(r'^$', 'myproject.views.home', name = 'home'),

# url(r'^blog/', include('blog.urls')),

url(r'^admin/', include(,


Now just run the server.

$ python runserver

And your admin interface is accessible at:

Once connected with your superuser account, you will see the following screen −

That interface will let you administrate Django groups and users, and all registered models in your app. The interface gives you the ability to do at least the "CRUD" (Create, Read, Update, Delete) operations on your models.

MyTetra Share v.0.60
Яндекс индекс цитирования