Commit Graph

88 Commits

Author SHA1 Message Date
Darks 21b863e0e2
Merge branch 'preprod' of gitea.planet-casio.com:devs/PCv5 2023-07-18 21:31:46 +02:00
Darks 20524d28c3
scripts: add modules to render helper 2023-07-15 20:36:44 +02:00
Darks 402e6699aa
fixed 'avancées de la v5' button 2023-07-04 21:45:35 +02:00
Darks 7e64a70eec Merge pull request 'Ajout de la page d’accueil en préprod' (#141) from landing_page into dev
Reviewed-on: https://gitea.planet-casio.com/devs/PCv5/pulls/141
2023-07-04 21:35:58 +02:00
Darks f6aefffc3c
homepage: still WIP, but better 2023-06-27 23:28:32 +02:00
Lephe c8f2d73bc2
shoutbox: add standalone shoutbox at /chat 2023-06-27 22:35:42 +02:00
Darks b892d9ae68
tabtitles: add configuration entry to set a prefix on tabtitles 2023-06-07 22:06:56 +02:00
Darks a5b2933727
Merge branch 'preprod' of gitea.planet-casio.com:devs/PCv5 2023-06-07 21:37:12 +02:00
Darks 0865ae0e67
erge branch 'dev' of gitea.planet-casio.com:devs/PCv5 into dev 2023-06-06 22:44:23 +02:00
Darks 3f8f8ab225
templates: added tabtitles to all relevant templates 2023-06-06 22:43:35 +02:00
Eragon 4eb4145846
template: Change the link/button to get to the topic about the current state of PCv5 2023-06-06 21:56:02 +02:00
Lephe 85830f1893
home: incident information 2023-05-20 21:17:29 +02:00
Eragon 6cc066b4d6
editor: Self-host the emoji-picker custom element. 2023-05-17 09:56:22 +02:00
Eragon 2b5485677e
editor: tests with emoji-picker-element for emoji picker
Note: we will need to self-host it if we keep it moving forward. This is
just a test, this commit should be reverted if not used in the end.
2023-05-15 16:17:28 +02:00
Eragon 277ec535e7
templates: Add slash at end of hardcoded urls 2022-11-15 16:19:32 +01:00
Lephe b047ed97af
programs: program creation + view + comments
This is very much a work in progress, but the main ideas are here.

[MIGRATION] This commit contains a new version of the schema.
2022-05-19 20:34:46 +01:00
Lephe 5a87d29c7f
account: make default avatar selection less hacky 2022-05-05 20:33:45 +01:00
Darks 9de0f9f823
Merge branch 'preprod' into 'master' 2022-04-26 23:49:11 +02:00
Darks faf5bd184d
navbar: properly generate links to recent topics 2022-04-26 20:40:56 +02:00
Lephe 262c5f22c8
navbar: fix links to news forums under "Actualités" 2022-04-26 15:15:30 +01:00
Darks 87d795959f
less (#97): first shot to Less
Quick switch, still may need some refacto and delete unused code
2021-07-14 16:30:45 +02:00
Lephe f75f1618bc
add a developer warning for slow requests (#63) 2021-07-07 18:42:17 +02:00
Eragon 6cbf5a51f9
Implémentation du "skip to content" #94 2021-04-28 19:30:41 +02:00
Darks 87ef91b9e3
login_as: add function to login as arbitrary account 2021-03-05 23:56:03 +01:00
Lephe 6f98cba65e
review of privileges and forum permissions
* Sorted privileges into categories, similar to the v4.3 style

Added privilege check utilities:
* Forum: is_news(), is_default_accessible() and is_default_postable()
* Member: can_access_forum(), can_post_in_forum(), can_edit_post(),
  and can_delete_post()

Unfortunately current_user is not a Guest when logged out, so one
cannot usually write current_user.can_*() without checking for
authentication first, so the checks are still somewhat verbose.

Reviewed forum permissions; the following permission issues have been
fixed (I have tested most but not all of them prior to fixing):

* app/routes/forum/index.py: Users that were not meant to access a
  forum could still obtain a listing of the topics
* app/routes/forum/topic.py: Users that were not meant to see topics
  could still read them by browsing the URL
* app/routes/forum/topic.py: Authenticated users could post in any
  topic, including ones that they should not have access to
* app/routes/posts/edit.py: Users with edit.posts (eg. mods) could edit
  and delete messages in forums they can't access (eg. creativecalc)

* app/templates/account/user.html: Users with admin panel access would
  see account editing links they can't use (affects developers)
* app/templates/base/navbar/forum.html: The "Forum" tab would list all
  forums including ones the user doesn't have access to
* app/templates/forum/index.html: Users would see every single forum,
  including ones they can't access
* app/template/widgets/thread.html: Anyone would see Edit/Delete links
  on every message, even though most were unusable

Miscellaneous changes:
* app/routes/forum/topic.py: Ordered comments by date as intended,
  which I assume worked by chance until now
* Removed the old assets/privs.txt files which is now superseded by the
  list implemented in app/data/groups.yaml

This commit changes group and forum information, run master.py with:
@> forums update
@> groups update
2021-02-26 18:32:45 +01:00
Eldeberen 41eaaa4c30
Merge branch 'preprod' on master 2021-02-23 00:15:29 +01:00
Eldeberen fabad32955
polls: add a panel to manage own polls 2021-02-20 01:28:08 +01:00
Eragon 227087ebbc
Issue #76 Refactoriser les messages flash
Javascript :
Supression du javascript inutile, l'entièreté du bloc du flash.

CSS :
Alignement plus correct des notifications flash, fini le fixed, 15%
place au margin auto.
Ajout d'une marge pour éviter l'effet «bloc».
Héritage des propriétés de couleur du texte et du fond de la classe supèrieure.

Modification des templates :
Les messages sont désormais chargés avant le contenu et après le header.
2020-10-01 22:16:15 +02:00
Darks 0d8dd70956
security: add CSRF protection globally
The decorator @check_csrf can be used to check CSRF protection when 
using GET links (like delete a post or logout)
2020-09-26 14:48:30 +02:00
Darks ad1042865b
Merge branch 'master' of gitea.planet-casio.com:devs/PCv5 2020-07-23 20:25:41 +02:00
Darks 2dd7863e89
Rebase master from preprod 2020-07-23 20:25:00 +02:00
Darks 77bcb99ea1
account: ADD mot de passe oublié 2020-07-21 22:12:18 +02:00
Darks 1ef055f629
enhancement: added modularity to converters 2020-07-17 00:17:11 +02:00
Lephe 17c78204a6
update the route model for the forum to <id>/<page>/<slug>
This works by bundling the topic object and page number in a pair during
conversion to/from URL, so that the slug can be computed effortlessly
and put in all links.
2020-07-16 23:58:21 +02:00
Darks f24d81b778
Merge branches comptes-fin-de-siderbar 2020-07-16 19:13:58 +02:00
Darks e3cdf6f0af
enhancement: moved account icon to bottom of navbar 2020-07-16 19:12:21 +02:00
Quentin Guidée 19678084dd
Déplace accounts à la fin de la navbar 2020-07-15 16:00:06 +02:00
Darks 04fb3225c1
refactor: passage aux variables CSS4 2020-07-13 22:54:34 +02:00
Darks e0e02d5423
Fix de merde n°2 2019-12-17 10:14:37 +01:00
Darks 83d5a0b385
Typo --' 2019-12-17 10:13:22 +01:00
Darks 4b8ce0334a
Ajout d'une favicon :D 2019-12-17 10:10:51 +01:00
Darks 9341c5883c
Premier jet sur les avatars 2019-12-09 23:24:05 +01:00
Darks 4427688193
Amélioration du menu
Les derniers topics redirigent automatique sur la dernière page du topic
2019-12-07 16:38:45 +01:00
Darks da96de2f14
Ajout d'un premier jet d'éditeur Js de LightScript 2019-12-04 22:16:29 +01:00
Darks cf61b43e17
Modification de la liste des topics actifs du menu
+ Correction de bugs
2019-12-04 13:58:48 +01:00
Darks e99e45b4ca
Modifications majeures du rendu du menu
- Les context processors sont dans un dossier à part
- Ajout du dynamisme dans le menu (récupération des derniers messages de 
topic)
2019-12-04 01:16:16 +01:00
Darks 087dd56cb2
Retiré le mode fixed du menu version mobile 2019-12-03 12:54:28 +01:00
Darks d4e1b05c29
Divers correctifs
- Le menu est utilisable sans Js (penser à mettre à jour les endpoints)
- Réorganisation des templates
- Ajout d'une page listant les outils
2019-11-28 14:14:35 +01: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 9f30bd36a0
forum: add the forum index page
Also prepare some functions for topic listings for each forum.
2019-09-09 08:11:38 +02:00