15 lines
312 B
Python
15 lines
312 B
Python
|
from pydantic import BaseModel
|
||
|
from typing import List
|
||
|
from app.config import PANDOC_PATH
|
||
|
|
||
|
|
||
|
class WikiPage(BaseModel):
|
||
|
name: str
|
||
|
title: str
|
||
|
credits: List[str]
|
||
|
standalone: bool
|
||
|
template: str
|
||
|
|
||
|
def get_file(self, filename: str) -> str:
|
||
|
return f'{PANDOC_PATH}/{self.name}/{filename}'
|