Loading muffin/payment_order/PaymentOrderCollection.py +7 −3 Original line number Diff line number Diff line Loading @@ -13,7 +13,7 @@ from .loader import load_pdf @dataclass(frozen=True, eq=False) class PaymentOrderCollection(Iterable[PaymentOrder]): base_dir: Path orders: tuple[PaymentOrder, ...] @classmethod def get(cls, studienfachschaft: Studienfachschaft, year: int) -> Self: Loading @@ -21,10 +21,14 @@ class PaymentOrderCollection(Iterable[PaymentOrder]): @classmethod def from_dir(cls, path_or_str: Path | str) -> Self: pass # TODO return cls( tuple( load_pdf(pdf) for pdf in Path(path_or_str).rglob("*.pdf") ) ) def __iter__(self) -> Iterator[PaymentOrder]: return (load_pdf(pdf) for pdf in self.base_dir.rglob("*.pdf")) return iter(self.orders) @property def by_budgetary_item_id(self): Loading Loading
muffin/payment_order/PaymentOrderCollection.py +7 −3 Original line number Diff line number Diff line Loading @@ -13,7 +13,7 @@ from .loader import load_pdf @dataclass(frozen=True, eq=False) class PaymentOrderCollection(Iterable[PaymentOrder]): base_dir: Path orders: tuple[PaymentOrder, ...] @classmethod def get(cls, studienfachschaft: Studienfachschaft, year: int) -> Self: Loading @@ -21,10 +21,14 @@ class PaymentOrderCollection(Iterable[PaymentOrder]): @classmethod def from_dir(cls, path_or_str: Path | str) -> Self: pass # TODO return cls( tuple( load_pdf(pdf) for pdf in Path(path_or_str).rglob("*.pdf") ) ) def __iter__(self) -> Iterator[PaymentOrder]: return (load_pdf(pdf) for pdf in self.base_dir.rglob("*.pdf")) return iter(self.orders) @property def by_budgetary_item_id(self): Loading