Improve statement form
This commit is contained in:
parent
08551a865d
commit
2991786444
5 changed files with 21 additions and 8 deletions
|
@ -1 +1 @@
|
||||||
end_of_line = "auto"
|
endOfLine = "auto"
|
||||||
|
|
|
@ -54,9 +54,12 @@ form {
|
||||||
background: none;
|
background: none;
|
||||||
z-index: 1;
|
z-index: 1;
|
||||||
|
|
||||||
&.value {
|
&[name*="value"] {
|
||||||
font-size: 1.5rem;
|
|
||||||
text-align: right;
|
text-align: right;
|
||||||
|
font-feature-settings: var(--num);
|
||||||
|
}
|
||||||
|
&[name*="date"] {
|
||||||
|
font-feature-settings: var(--num);
|
||||||
}
|
}
|
||||||
|
|
||||||
&:focus {
|
&:focus {
|
||||||
|
|
|
@ -495,3 +495,8 @@ ul.statements {
|
||||||
border-style: dashed;
|
border-style: dashed;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.date,
|
||||||
|
.value {
|
||||||
|
font-feature-settings: var(--num);
|
||||||
|
}
|
||||||
|
|
|
@ -60,8 +60,3 @@ table {
|
||||||
text-align: center;
|
text-align: center;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.date,
|
|
||||||
.value {
|
|
||||||
font-feature-settings: var(--num);
|
|
||||||
}
|
|
||||||
|
|
|
@ -15,6 +15,15 @@ class StatementForm(NummiForm):
|
||||||
"file": NummiFileInput,
|
"file": NummiFileInput,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
meta_fieldsets = [
|
||||||
|
[
|
||||||
|
["account"],
|
||||||
|
["start_date", "start_value"],
|
||||||
|
["date", "value"],
|
||||||
|
["file"],
|
||||||
|
],
|
||||||
|
]
|
||||||
|
|
||||||
def __init__(self, *args, **kwargs):
|
def __init__(self, *args, **kwargs):
|
||||||
_user = kwargs.get("user")
|
_user = kwargs.get("user")
|
||||||
_disable_account = kwargs.pop("disable_account", False)
|
_disable_account = kwargs.pop("disable_account", False)
|
||||||
|
@ -30,6 +39,7 @@ class StatementForm(NummiForm):
|
||||||
label=_("Add transactions"),
|
label=_("Add transactions"),
|
||||||
required=False,
|
required=False,
|
||||||
)
|
)
|
||||||
|
|
||||||
if _disable_account:
|
if _disable_account:
|
||||||
self.fields["account"].disabled = True
|
self.fields["account"].disabled = True
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue