forked from DGNum/gestioCOF
Gestion négatif d'un compte
- 3 paramètres ajustables : date jusqu'à, montant max, décalage de balance
This commit is contained in:
parent
4e6f12bb6d
commit
e89f8fd6a5
3 changed files with 65 additions and 3 deletions
|
@ -7,7 +7,7 @@ from django.contrib.admin.widgets import FilteredSelectMultiple
|
|||
from django.forms import modelformset_factory
|
||||
from django.utils import timezone
|
||||
from kfet.models import (Account, Checkout, Article, OperationGroup, Operation,
|
||||
CheckoutStatement, ArticleCategory, Settings)
|
||||
CheckoutStatement, ArticleCategory, Settings, AccountNegative)
|
||||
from gestioncof.models import CofProfile
|
||||
|
||||
# -----
|
||||
|
@ -104,6 +104,15 @@ class GroupForm(forms.ModelForm):
|
|||
model = Group
|
||||
fields = ['name', 'permissions']
|
||||
|
||||
class AccountNegativeForm(forms.ModelForm):
|
||||
class Meta:
|
||||
model = AccountNegative
|
||||
fields = ['authz_overdraft_amount', 'authz_overdraft_until',
|
||||
'balance_offset', 'comment']
|
||||
widgets = {
|
||||
'authz_overdraft_until': DateTimeWidget(),
|
||||
}
|
||||
|
||||
# -----
|
||||
# Checkout forms
|
||||
# -----
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue