Skip to content

Commit

Permalink
Split docs into multiple pages for sphinx.
Browse files Browse the repository at this point in the history
  • Loading branch information
Ron DuPlain committed Mar 14, 2011
1 parent 6c06d07 commit 30b3ded
Show file tree
Hide file tree
Showing 10 changed files with 307 additions and 252 deletions.
Binary file added docs/_static/flask-sqlalchemy-small.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
25 changes: 25 additions & 0 deletions docs/_templates/sidebarintro.html
@@ -0,0 +1,25 @@
<h3>About Flask-SQLAlchemy</h3>
<p>
Flask-SQLAlchemy provides a SQLAlchemy extension to Flask.
Flask is a micro webdevelopment framework for Python. You are currently
looking at the documentation of the development version. Things are
not stable yet, but if you have some feedback,
<a href="mailto:armin.ronacher@active-4.com">let me know</a>.
</p>
<!--
<h3>Other Formats</h3>
<p>
You can download the documentation in other formats as well:
</p>
<ul>
<li><a href="http://flask.pocoo.org/docs/flask-docs.pdf">as PDF</a>
<li><a href="http://flask.pocoo.org/docs/flask-docs.zip">as zipped HTML</a>
</ul>
-->
<h3>Useful Links</h3>
<ul>
<li><a href="http://flask.pocoo.org/">The Flask Website</a></li>
<li><a href="http://pypi.python.org/pypi/Flask-SQLAlchemy">Flask-SQLAlchemy @ PyPI</a></li>
<li><a href="http://github.com/mitsuhiko/flask-sqlalchemy">Flask-SQLAlchemy @ github</a></li>
<li><a href="http://github.com/mitsuhiko/flask-sqlalchemy/issues">Issue Tracker</a></li>
</ul>
3 changes: 3 additions & 0 deletions docs/_templates/sidebarlogo.html
@@ -0,0 +1,3 @@
<p class="logo"><a href="{{ pathto(master_doc) }}">
<img class="logo" src="{{ pathto('_static/flask-sqlalchemy-small.png', 1) }}" alt="Logo"/>
</a></p>
59 changes: 59 additions & 0 deletions docs/api.rst
@@ -0,0 +1,59 @@
API
---

.. module:: flaskext.sqlalchemy

This part of the documentation documents all the public classes and
functions in Flask-SQLAlchemy.

Configuration
`````````````

.. autoclass:: SQLAlchemy
:members:

.. attribute:: Query

The :class:`BaseQuery` class.

Models
``````

.. autoclass:: Model
:members:

.. autoclass:: BaseQuery
:members: get, get_or_404, paginate, first_or_404

.. method:: all()

Return the results represented by this query as a list. This
results in an execution of the underlying query.

.. method:: order_by(*criterion)

apply one or more ORDER BY criterion to the query and return the
newly resulting query.

.. method:: limit(limit)

Apply a LIMIT to the query and return the newly resulting query.

.. method:: offset(offset)

Apply an OFFSET to the query and return the newly resulting
query.

.. method:: first()

Return the first result of this query or `None` if the result
doesn’t contain any rows. This results in an execution of the
underlying query.

Utilities
`````````

.. autoclass:: Pagination
:members:

.. autofunction:: get_debug_queries
1 change: 1 addition & 0 deletions docs/changelog.rst
@@ -0,0 +1 @@
.. include:: ../CHANGES
5 changes: 2 additions & 3 deletions docs/conf.py
Expand Up @@ -98,14 +98,13 @@

# The theme to use for HTML and HTML Help pages. See the documentation for
# a list of builtin themes.
html_theme = 'flask_small'
html_theme = 'flask'

# Theme options are theme-specific and customize the look and feel of a theme
# further. For a list of options available for each theme, see the
# documentation.
html_theme_options = {
'index_logo': 'flask-sqlalchemy.png',
'github_fork': 'mitsuhiko/flask-sqlalchemy'
'touch_icon': 'touch-icon.png'
}

# Add any paths that contain custom themes here, relative to this directory.
Expand Down
34 changes: 34 additions & 0 deletions docs/contents.rst.inc
@@ -0,0 +1,34 @@
User's Guide
------------

This part of the documentation will show you how to get started in using
Flask-SQLAlchemy with Flask.

.. toctree::
:maxdepth: 2

quickstart
signals

API Reference
-------------

If you are looking for information on a specific function, class or
method, this part of the documentation is for you.

.. toctree::
:maxdepth: 2

api

Additional Notes
----------------

See Flask's license_ for legal information governing this project.

.. toctree::
:maxdepth: 2

changelog

.. _license: http://flask.pocoo.org/docs/license/

0 comments on commit 30b3ded

Please sign in to comment.