fix #234, this adds formal install instructions to the docs and includes reorganization of the docs

This commit is contained in:
Daniel Greenfeld 2013-07-06 09:55:29 +02:00
parent 4aec1a3836
commit 12579fdd0e
9 changed files with 74 additions and 51 deletions

View file

@ -52,6 +52,7 @@ Requirements
Installation
============
Use pip to install from PyPI:
.. code-block:: python
@ -85,9 +86,6 @@ Add djadmin2 urls to your URLconf:
...
url(r'^admin2/', include(djadmin2.default.urls)),
)
How to write django-admin2 modules

View file

@ -1,22 +0,0 @@
================
Architecture
================
.. warning:: This is out of date and will be updated shortly.
Workflow Pieces
----------------
* Apps
* Apps.models
* AdminObj
* Appstore
Workflow
----------------
1. Instantiate Appstore
2. Loop through the Apps then models per App
3. Admin2s are created from models: djadmin2.models.register(Poll)
4. Admin2s contain methods/properties necessaey for UI
5. Views

View file

@ -11,7 +11,8 @@
# All configuration values have a default; values that are commented out
# serve to show the default.
import sys, os
import os
import sys
# If extensions (or modules to document with autodoc) are in another directory,
# add these directories to sys.path here. If the directory is relative to the
@ -62,9 +63,9 @@ copyright = u'2013, Daniel Greenfeld'
# built documents.
#
# The short X.Y version.
version = '0.4'
version = '0.5'
# The full version, including alpha/beta/rc tags.
release = '0.4.0'
release = '0.5.0'
# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.

View file

@ -1,29 +1,33 @@
=========================================
Welcome to django-admin2's documentation!
=========================================
.. image:: https://travis-ci.org/pydanny/django-admin2.png
:alt: Build Status
:target: https://travis-ci.org/pydanny/django-admin2
**Warning:** This project is currently in an **alpha** state and currently not meant for real projects.
One of the most useful parts of ``django.contrib.admin`` is the ability to configure various views that touch and alter data. django-admin2 is a complete rewrite of that library using modern Class-Based Views and enjoying a design focused on extendibility and adaptability. By starting over, we can avoid the legacy code and make it easier to write extensions and themes.
**django-admin2** aims to replace django's built-in admin that lives in
``django.contrib.admin``. Come and help us, have a look at the
:doc:`contributing` page and see our `GitHub`_ page.
``django.contrib.admin``. Come and help us, read the :doc:`design` and
:doc:`contributing` pages, and visit the `GitHub`_ project.
This project is intentionally backwards-incompatible with ``django.contrib.admin``.
Requirements
Features
=============
* Django 1.5+
* Python 2.7+ or Python 3.3+
* django-braces
* django-extra-views
* django-floppyforms
* django-rest-framework
* Sphinx (for documentation)
* Rewrite of the Django Admin backend
* Drop-in themes
* Built-in RESTful API
Basic API
==============
Our goal is to make this API work:
If you've worked with Django, this implementation should look familiar:
.. code-block:: python
@ -56,30 +60,26 @@ Content
.. toctree::
:maxdepth: 2
installation
contributing
design
architecture
api
themes
built-in-views
meta
tutorial
Reference
-----------
Most of django-admin2 is designed to be extensible, which means with a little bit of Python code you can do amazing things. You can easily create custom actions, implement alternative forms, set permissions per view, add new views, and even trivially replace the base views with those of your own design. Combined with the REST API, django-admin2 provides a wealth of customization options.
One of the core design goals of django-admin2 is to embrace object-oriented design, making it easy to take one of the built-in classes and extend it to suit your needs.
.. toctree::
:maxdepth: 2
ref/themes
ref/api
ref/actions
ref/forms
ref/permissions
ref/views
ref/built-in-views
ref/meta
Indices and tables
==================

46
docs/installation.rst Normal file
View file

@ -0,0 +1,46 @@
============
Installation
============
Adding django-admin2 to your project
====================================
Use pip to install from PyPI:
.. code-block:: python
pip install django-admin2
Add djadmin2 and rest_framework to your settings file:
.. code-block:: python
INSTALLED_APPS = (
...
'djadmin2',
'rest_framework', # for the browsable API templates
...
)
Add djadmin2 urls to your URLconf:
.. code-block:: python
# urls.py
from django.conf.urls import patterns, include
import djadmin2
djadmin2.default.autodiscover()
urlpatterns = patterns(
...
url(r'^admin2/', include(djadmin2.default.urls)),
)
Development Installation
=========================
See :docs:`contributing`.

View file

@ -1,5 +1,5 @@
API
===
RESTful API
=============
**django-admin2** comes with a builtin REST-API for accessing all the
resources you can get from the frontend via JSON.