Added the type hint and the documentation for the obj parameter of the post_update method of the AccountForm and CurrencyForm forms.
This commit is contained in:
parent
a73e3204b9
commit
a4c89f1494
@ -96,9 +96,10 @@ class AccountForm(FlaskForm):
|
||||
setattr(self, "__post_update",
|
||||
lambda: sort_accounts_in(prev_base_code, obj.id))
|
||||
|
||||
def post_update(self, obj) -> None:
|
||||
def post_update(self, obj: Account) -> None:
|
||||
"""The post-processing after the update.
|
||||
|
||||
:param obj: The account object.
|
||||
:return: None
|
||||
"""
|
||||
current_user_pk: int = get_current_user_pk()
|
||||
|
@ -83,9 +83,10 @@ class CurrencyForm(FlaskForm):
|
||||
obj.created_by_id = current_user_pk
|
||||
obj.updated_by_id = current_user_pk
|
||||
|
||||
def post_update(self, obj) -> None:
|
||||
def post_update(self, obj: Currency) -> None:
|
||||
"""The post-processing after the update.
|
||||
|
||||
:param obj: The currency object.
|
||||
:return: None
|
||||
"""
|
||||
current_user_pk: int = get_current_user_pk()
|
||||
|
Loading…
Reference in New Issue
Block a user