Update options field in TemplateFieldCreator class
This commit is contained in:
parent
8324c40074
commit
a74b86e93b
1 changed files with 2 additions and 2 deletions
|
|
@ -1,5 +1,5 @@
|
||||||
from abc import ABC
|
from abc import ABC
|
||||||
from typing import Any, Optional, Union
|
from typing import Any, Callable, Optional, Union
|
||||||
|
|
||||||
from pydantic import BaseModel
|
from pydantic import BaseModel
|
||||||
|
|
||||||
|
|
@ -35,7 +35,7 @@ class TemplateFieldCreator(BaseModel, ABC):
|
||||||
password: bool = False
|
password: bool = False
|
||||||
"""Specifies if the field is a password. Defaults to False."""
|
"""Specifies if the field is a password. Defaults to False."""
|
||||||
|
|
||||||
options: list[str] = []
|
options: Union[list[str], Callable] = []
|
||||||
"""List of options for the field. Only used when is_list=True. Default is an empty list."""
|
"""List of options for the field. Only used when is_list=True. Default is an empty list."""
|
||||||
|
|
||||||
name: str = ""
|
name: str = ""
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue