Commit Graph

10 Commits

Author SHA1 Message Date
Darks 3fb3ee40d2
fix: better PEP8
Flake8 returns less errors. I ignored lots of them though
2020-08-05 22:52:56 +02:00
Darks 3a35c26bd7
forum: add pagination to topic list (#64) 2020-08-02 17:28:43 +02:00
Lephe 03c577316f
thread: add a reference to the owner post 2020-08-02 11:01:08 +02:00
Lephe d3f137b92d
programs: add models for programs and topic promotions (#20)
Not tested yet since there is a lack of tools to manipulate comments,
topics and programs. The /programmes routes is used to display a list of
all programs, temporarily.
2020-08-01 15:11:19 +02:00
Darks e35910ee76
config: refactor configuration values
- System/host config values stay in `config.py`
- Application config values moves in corresponding models
- BREAK: AVATAR_FOLDER becomes DATA_FOLDER. Edit your local config if 
needed
2020-07-26 16:50:07 +02:00
Lephe 3ad3eca470
forum: list subforum topics
Also introduces a 'date' filter that displays date in a readable format.
2019-09-09 08:11:39 +02:00
Lephe 8a0ba309e0
forum: restructure models and add topic creation
This changes fixes #25 by restructuring the forum models in a way
compatible with the polymorphic behavior of SQLAlchemy. Incidentally,
the new form turns out to be more appropriate for our use than the
polymorphic one originally used.

The migration for this task is non-trivial because the Thread class was
created with a foreign-key id which thus had no auto-increment or
associated sequence. The most reliable way of getting it back was to
recreate the table because SQLAlchemy ony performs automated sequence
introduction at table creation time. Four separate migration files
perform the whole change.

This commit also adds views and forms to create topics, and the
boilerplate for an advanced markup editor that can be used as a widget.
2019-09-09 08:11:38 +02:00
Lephe eeaab86d0a forum: improve model relationships (so that it works) 2019-08-24 19:17:13 +02:00
Lephe 11b19af199 forum: provide suitable migrations for the database
First migrate without the foreign key to create the tables, then add the
foreign key in a second migration.

Also removed unneeded imports that caused dependency cycles.

Minor "style" edits with the ambiguous use of super and unnecessary
db.Model inheritance.
2019-08-21 16:50:23 +02:00
Darks 81c910832b
Ajout des post/thread/comment/etc. 2019-08-20 17:34:00 +02:00