From 91e730cee5dbfbc7ed499a86ce06d4511db65732 Mon Sep 17 00:00:00 2001
From: Dominik George <dominik.george@teckids.org>
Date: Thu, 15 Aug 2019 13:41:05 +0200
Subject: [PATCH] Add first documentation for core models.

---
 biscuit/core/models.py      | 4 ++++
 docs/index.rst              | 1 +
 docs/ref/00_index.rst       | 7 +++++++
 docs/ref/core/01_models.rst | 5 +++++
 4 files changed, 17 insertions(+)
 create mode 100644 docs/ref/00_index.rst
 create mode 100644 docs/ref/core/01_models.rst

diff --git a/biscuit/core/models.py b/biscuit/core/models.py
index e4e06d21e..f791850d8 100644
--- a/biscuit/core/models.py
+++ b/biscuit/core/models.py
@@ -14,6 +14,10 @@ class School(models.Model):
 
 
 class Person(SchoolRelated):
+    """ A model describing any person related to a school, including, but not
+    limited to, students, teachers and guardians (parents).
+    """
+
     class Meta:
         unique_together = [['school', 'short_name'], ['school', 'import_ref']]
 
diff --git a/docs/index.rst b/docs/index.rst
index d240949b8..c21b74031 100644
--- a/docs/index.rst
+++ b/docs/index.rst
@@ -11,6 +11,7 @@ Welcome to BiscuIT's documentation!
    :caption: Contents:
 
    dev/00_index
+   ref/00_index
 
 
 Indices and tables
diff --git a/docs/ref/00_index.rst b/docs/ref/00_index.rst
new file mode 100644
index 000000000..1f1524f16
--- /dev/null
+++ b/docs/ref/00_index.rst
@@ -0,0 +1,7 @@
+API and models reference
+========================
+
+.. toctree::
+   :glob:
+
+   core/*
diff --git a/docs/ref/core/01_models.rst b/docs/ref/core/01_models.rst
new file mode 100644
index 000000000..bfec932dd
--- /dev/null
+++ b/docs/ref/core/01_models.rst
@@ -0,0 +1,5 @@
+Core data models
+================
+
+.. automodule:: biscuit.core.models
+   :members:
-- 
GitLab