Skip to content

Commit

Permalink
feat: add banner
Browse files Browse the repository at this point in the history
Signed-off-by: Dup4 <lyuzhi.pan@gmail.com>
  • Loading branch information
Dup4 committed Dec 4, 2023
1 parent 344406d commit 1b991ae
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions xcpcio_board_spider/type/contest.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ def __init__(self,
medal: typing.Any = {},
balloon_color: typing.List[Color] = None,
logo: Image = None,
banner: Image = None,
options: ContestOptions = None,
):
self.contest_name = contest_name
Expand Down Expand Up @@ -56,6 +57,11 @@ def __init__(self,
else:
self.logo = None

if banner is not None:
self.banner = Image(**banner)
else:
self.banner = None

if options is not None:
self.options = options
else:
Expand Down Expand Up @@ -118,6 +124,9 @@ def get_dict(self):
if self.logo is not None:
obj["logo"] = self.logo.get_dict

if self.banner is not None:
obj["banner"] = self.banner.get_dict

obj["options"] = self.options.get_dict

return obj
Expand Down

0 comments on commit 1b991ae

Please sign in to comment.