remove public puzzle.title from private ConfigModel
This commit is contained in:
parent
47eb42f0f5
commit
e9ef7f67e3
3 changed files with 2 additions and 5 deletions
|
@ -21,7 +21,6 @@ async def is_admin(
|
||||||
|
|
||||||
class ConfigModel(BaseModel):
|
class ConfigModel(BaseModel):
|
||||||
class __Puzzle(BaseModel):
|
class __Puzzle(BaseModel):
|
||||||
title: str
|
|
||||||
solution: str
|
solution: str
|
||||||
begin: date
|
begin: date
|
||||||
end: date
|
end: date
|
||||||
|
@ -65,7 +64,6 @@ async def get_config_model(
|
||||||
return ConfigModel.model_validate(
|
return ConfigModel.model_validate(
|
||||||
{
|
{
|
||||||
"puzzle": {
|
"puzzle": {
|
||||||
"title": cfg.puzzle.title,
|
|
||||||
"solution": cfg.puzzle.solution,
|
"solution": cfg.puzzle.solution,
|
||||||
"begin": date.today(), # TODO
|
"begin": date.today(), # TODO
|
||||||
"end": date.today(), # TODO
|
"end": date.today(), # TODO
|
||||||
|
|
|
@ -7,7 +7,8 @@
|
||||||
<h4>Rätsel</h4>
|
<h4>Rätsel</h4>
|
||||||
<dl>
|
<dl>
|
||||||
<dt>Titel</dt>
|
<dt>Titel</dt>
|
||||||
<dd>{{ config_model.puzzle.title }}</dd>
|
<!-- TODO -->
|
||||||
|
<dd>Advent22</dd>
|
||||||
|
|
||||||
<dt>Lösung</dt>
|
<dt>Lösung</dt>
|
||||||
<dd>{{ config_model.puzzle.solution }}</dd>
|
<dd>{{ config_model.puzzle.solution }}</dd>
|
||||||
|
@ -140,7 +141,6 @@ interface Credentials {
|
||||||
export default class extends Vue {
|
export default class extends Vue {
|
||||||
public config_model: ConfigModel = {
|
public config_model: ConfigModel = {
|
||||||
puzzle: {
|
puzzle: {
|
||||||
title: "Advent22",
|
|
||||||
solution: "ABCDEFGHIJKLMNOPQRSTUVWX",
|
solution: "ABCDEFGHIJKLMNOPQRSTUVWX",
|
||||||
begin: "01.12.2023",
|
begin: "01.12.2023",
|
||||||
end: "24.12.2023",
|
end: "24.12.2023",
|
||||||
|
|
|
@ -1,6 +1,5 @@
|
||||||
export interface ConfigModel {
|
export interface ConfigModel {
|
||||||
puzzle: {
|
puzzle: {
|
||||||
title: string;
|
|
||||||
solution: string;
|
solution: string;
|
||||||
begin: string;
|
begin: string;
|
||||||
end: string;
|
end: string;
|
||||||
|
|
Loading…
Reference in a new issue