Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Digitale Keilschrift Bibliothek to Ext Nos #593

Merged
merged 2 commits into from
Jan 5, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions ebl/fragmentarium/application/fragment_fields_schemas.py
Original file line number Diff line number Diff line change
Expand Up @@ -145,6 +145,9 @@ class ExternalNumbersSchema(Schema):
oracc_numbers = fields.List(
fields.String(), load_default=(), data_key="oraccNumbers"
)
digitale_keilschrift_bibliothek = fields.String(
load_default="", data_key="digitaleKeilschriftBibliothek"
)
seal_numbers = fields.List(fields.String(), load_default=(), data_key="sealNumbers")

@post_load
Expand Down
5 changes: 5 additions & 0 deletions ebl/fragmentarium/domain/fragment_external_numbers.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ class ExternalNumbers:
philadelphia_number: str = ""
achemenet_number: str = ""
nabucco_number: str = ""
digitale_keilschrift_bibliothek: str = ""
yale_peabody_number: str = ""
oracc_numbers: Sequence[str] = ()
seal_numbers: Sequence[str] = ()
Expand Down Expand Up @@ -100,6 +101,10 @@ def achemenet_number(self) -> str:
def nabucco_number(self) -> str:
return self._get_external_number("nabucco")

@property
def digitale_keilschrift_bibliothek(self) -> str:
return self._get_external_number("digitale_keilschrift_bibliothek")

@property
def philadelphia_number(self) -> str:
return self._get_external_number("philadelphia_number")
Expand Down
3 changes: 3 additions & 0 deletions ebl/tests/factories/fragment.py
Original file line number Diff line number Diff line change
Expand Up @@ -199,6 +199,9 @@ class Meta:
yale_peabody_number = factory.Sequence(lambda n: f"yale-peabody-number-{n}")
achemenet_number = factory.Sequence(lambda n: f"achemenet-number-{n}")
nabucco_number = factory.Sequence(lambda n: f"nabucco-number-{n}")
digitale_keilschrift_bibliothek = factory.Sequence(
lambda n: f"digitale-keilschrift-bibliothek-{n}"
)
oracc_numbers = factory.List(
[factory.Sequence(lambda n: f"oracc-number-{n}")], TupleFactory
)
Expand Down
Loading