mirror of
https://gitlab.crans.org/bde/nk20
synced 2024-11-30 04:13:01 +00:00
PEP8 compliance
This commit is contained in:
parent
526744052e
commit
46ec16d8c9
@ -6,9 +6,10 @@ from django.db.models import F
|
||||
from django_tables2.utils import A
|
||||
|
||||
from .models.notes import Alias
|
||||
from .models.transactions import Transaction
|
||||
from .models.transactions import Transaction, TransactionTemplate
|
||||
from .templatetags.pretty_money import pretty_money
|
||||
|
||||
|
||||
class HistoryTable(tables.Table):
|
||||
class Meta:
|
||||
attrs = {
|
||||
@ -16,7 +17,7 @@ class HistoryTable(tables.Table):
|
||||
'table table-condensed table-striped table-hover'
|
||||
}
|
||||
model = Transaction
|
||||
exclude = ("polymorphic_ctype",)
|
||||
exclude = ("polymorphic_ctype", )
|
||||
template_name = 'django_tables2/bootstrap4.html'
|
||||
sequence = ('...', 'total', 'valid')
|
||||
|
||||
@ -28,12 +29,13 @@ class HistoryTable(tables.Table):
|
||||
.order_by(('-' if is_descending else '') + 'total')
|
||||
return (queryset, True)
|
||||
|
||||
def render_amount(self,value):
|
||||
def render_amount(self, value):
|
||||
return pretty_money(value)
|
||||
|
||||
def render_total(self,value):
|
||||
def render_total(self, value):
|
||||
return pretty_money(value)
|
||||
|
||||
|
||||
class AliasTable(tables.Table):
|
||||
class Meta:
|
||||
attrs = {
|
||||
|
Loading…
Reference in New Issue
Block a user