mirror of https://gitlab.crans.org/bde/nk20
Merge branch 'beta' into 'master'
Few fixes Closes #61 See merge request bde/nk20!110
This commit is contained in:
commit
2b2dde85dc
|
@ -9,7 +9,7 @@
|
|||
vars:
|
||||
mirror: deb.debian.org
|
||||
note:
|
||||
server_name: bde-note.adh.crans.org
|
||||
server_name: note.crans.org
|
||||
roles:
|
||||
- 1-apt-basic
|
||||
- 2-nk20
|
||||
|
|
|
@ -7,7 +7,6 @@ from django.contrib.auth.models import User
|
|||
from django.test import TestCase
|
||||
from django.urls import reverse
|
||||
from django.utils import timezone
|
||||
|
||||
from activity.models import Activity, ActivityType, Guest, Entry
|
||||
from member.models import Club
|
||||
|
||||
|
|
|
@ -102,7 +102,7 @@ class Note(PolymorphicModel):
|
|||
|
||||
super().save(*args, **kwargs)
|
||||
|
||||
if not Alias.objects.filter(name=str(self)).exists():
|
||||
if not Alias.objects.filter(normalized_name=Alias.normalize(str(self))).exists():
|
||||
a = Alias(name=str(self))
|
||||
a.clean()
|
||||
|
||||
|
|
|
@ -46,7 +46,8 @@ class HistoryTable(tables.Table):
|
|||
}
|
||||
)
|
||||
|
||||
created_at = tables.DateTimeColumn(format='Y-m-d H:i:s',
|
||||
created_at = tables.DateTimeColumn(
|
||||
format='Y-m-d H:i:s',
|
||||
attrs={
|
||||
"td": {
|
||||
"class": "text-nowrap",
|
||||
|
|
|
@ -37,7 +37,7 @@ SPDX-License-Identifier: GPL-2.0-or-later
|
|||
<div class="row">
|
||||
{# Preview note profile (picture, username and balance) #}
|
||||
<div class="col-md-3" id="note_infos_div">
|
||||
<div class="card bg-light border-success shadow mb-4">
|
||||
<div class="card bg-light border-success shadow mb-4 text-center">
|
||||
<a id="profile_pic_link" href="#"><img src="{% static "member/img/default_picture.png" %}"
|
||||
id="profile_pic" alt="" class="img-fluid rounded mx-auto"></a>
|
||||
<div class="card-body text-center">
|
||||
|
|
|
@ -2631,6 +2631,22 @@
|
|||
"description": "Modifier la raison d'invalidité d'une transaction si c'est possible"
|
||||
}
|
||||
},
|
||||
{
|
||||
"model": "permission.permission",
|
||||
"pk": 169,
|
||||
"fields": {
|
||||
"model": [
|
||||
"note",
|
||||
"noteclub"
|
||||
],
|
||||
"query": "{\"pk\": [\"club\", \"pk\"]}",
|
||||
"type": "change",
|
||||
"mask": 1,
|
||||
"field": "display_image",
|
||||
"permanent": false,
|
||||
"description": "Changer l'image de la note de son club"
|
||||
}
|
||||
},
|
||||
{
|
||||
"model": "permission.role",
|
||||
"pk": 1,
|
||||
|
@ -2726,7 +2742,8 @@
|
|||
47,
|
||||
49,
|
||||
50,
|
||||
141
|
||||
141,
|
||||
169
|
||||
]
|
||||
}
|
||||
},
|
||||
|
@ -3001,7 +3018,11 @@
|
|||
162,
|
||||
163,
|
||||
164,
|
||||
165
|
||||
165,
|
||||
166,
|
||||
167,
|
||||
168,
|
||||
169
|
||||
]
|
||||
}
|
||||
},
|
||||
|
|
|
@ -1 +1 @@
|
|||
Subproject commit 7479671b3f6c499958d3ad991eb54de3010f4da8
|
||||
Subproject commit 4f5a794798a48cbbf10b42f0a519743fcbb96c33
|
|
@ -7,7 +7,6 @@ from django.core.exceptions import ValidationError
|
|||
from django.db.models import Q
|
||||
from django.test import TestCase
|
||||
from django.urls import reverse
|
||||
|
||||
from member.models import Membership, Club
|
||||
from note.models import SpecialTransaction, NoteSpecial, Transaction
|
||||
from treasury.models import Invoice, Product, Remittance, RemittanceType, SogeCredit
|
||||
|
|
10
note.cron
10
note.cron
|
@ -3,20 +3,20 @@
|
|||
|
||||
# m h dom mon dow user command
|
||||
# Envoyer les mails en attente
|
||||
* * * * * root cd /var/www/note_kfet && env/bin/python manage.py send_mail >> /var/www/note_kfet/cron_mail.log
|
||||
* * * * * root cd /var/www/note_kfet && env/bin/python manage.py retry_deferred >> /var/www/note_kfet/cron_mail_deferred.log
|
||||
00 0 * * * root cd /var/www/note_kfet && env/bin/python manage.py purge_mail_log 7 >> /var/www/note_kfet/cron_mail_purge.log
|
||||
* * * * * root cd /var/www/note_kfet && env/bin/python manage.py send_mail
|
||||
* * * * * root cd /var/www/note_kfet && env/bin/python manage.py retry_deferred
|
||||
00 0 * * * root cd /var/www/note_kfet && env/bin/python manage.py purge_mail_log 7
|
||||
# Faire une sauvegarde de la base de données
|
||||
00 2 * * * root cd /var/www/note_kfet && apps/scripts/shell/backup_db
|
||||
# Vérifier la cohérence de la base et mailer en cas de problème
|
||||
00 4 * * * root cd /var/www/note_kfet && env/bin/python manage.py check_consistency --sum-all --check-all --mail
|
||||
# Mettre à jour le wiki (modification sans (dé)validation, activités passées)
|
||||
#30 5 * * * root cd /var/www/note_kfet && env/bin/python manage.py refresh_activities --raw --comment refresh
|
||||
#30 5 * * * root cd /var/www/note_kfet && env/bin/python manage.py refresh_activities --raw --comment refresh --wiki
|
||||
# Spammer les gens en négatif
|
||||
00 5 * * 2 root cd /var/www/note_kfet && env/bin/python manage.py send_mail_to_negative_balances --spam
|
||||
# Envoyer le rapport mensuel aux trésoriers et respos info
|
||||
00 8 6 * * root cd /var/www/note_kfet && env/bin/python manage.py send_mail_to_negative_balances --report
|
||||
# Envoyer les rapports aux gens
|
||||
55 6 * * * root cd /var/www/note_kfet && env/bin/python manage.py send_reports
|
||||
# Envoyer les rapports aux gens
|
||||
# Mettre à jour les boutons mis en avant
|
||||
00 9 * * * root cd /var/www/note_kfet && env/bin/python manage.py refresh_highlighted_buttons
|
||||
|
|
Loading…
Reference in New Issue