Added the default_spec() method to Period, and applied it to the views in the accounting application.
This commit is contained in:
1 parent
79337272ec
commit
e64089f06f
2 files changed
+15
-13
No files matched your search
@@ -314,6 +314,15 @@ class Period:
|
||||
"defaultDate": self.chosen_month,
|
||||
})
|
||||
|
||||
@staticmethod
|
||||
def default_spec():
|
||||
"""Returns the specification for the default period.
|
||||
|
||||
Returns:
|
||||
str: The specification for the default period
|
||||
"""
|
||||
return dateformat.format(timezone.localdate(), "Y-m")
|
||||
|
||||
class Parser:
|
||||
"""The period parser.
|
||||
|
||||
|
||||
Reference in new issue
Block a user