1
0
mirror of https://gitlab.crans.org/bde/nk20 synced 2025-06-30 13:11:09 +02:00
This commit is contained in:
Nicolas Margulies
2022-09-28 12:50:11 +02:00
parent f9850b61e3
commit 3fc6be078c
4 changed files with 20 additions and 20 deletions

View File

@ -325,8 +325,8 @@ class SpecialTransaction(Transaction):
def clean(self):
# SpecialTransaction are only possible with NoteSpecial object
if self.is_credit() == self.is_debit():
raise(ValidationError(_("A special transaction is only possible between a"
" Note associated to a payment method and a User or a Club")))
raise (ValidationError(_("A special transaction is only possible between a"
" Note associated to a payment method and a User or a Club")))
@transaction.atomic
def save(self, *args, **kwargs):

View File

@ -172,6 +172,7 @@ class TrustTable(tables.Table):
else '')}},
verbose_name=_("Delete"),)
class TrustedTable(tables.Table):
class Meta:
attrs = {
@ -184,7 +185,7 @@ class TrustedTable(tables.Table):
show_header = False
trusting = tables.Column(attrs={
'td': {'class': 'text-center', 'width':'100%'}})
'td': {'class': 'text-center', 'width': '100%'}})
trust_back = tables.Column(
verbose_name=_("Trust back"),
@ -200,7 +201,7 @@ class TrustedTable(tables.Table):
def render_trust_back(self, record):
user_note = record.trusted
trusting_note = record.trusting
if Trust.objects.filter(trusted=trusting_note, trusting=user_note) :
if Trust.objects.filter(trusted=trusting_note, trusting=user_note):
return ""
val = '<button id="'
val += str(record.pk)