Skip to content

Commit

Permalink
Add Achemenet to External Resources
Browse files Browse the repository at this point in the history
  • Loading branch information
ejimsan committed Nov 2, 2023
1 parent 2edefbf commit 05f987f
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 0 deletions.
1 change: 1 addition & 0 deletions ebl/fragmentarium/application/fragment_schema.py
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,7 @@ class ExternalNumbersSchema(Schema):
yale_peabody_number = fields.String(load_default="", data_key="yalePeabodyNumber")
louvre_number = fields.String(load_default="", data_key="louvreNumber")
philadelphia_number = fields.String(load_default="", data_key="philadelphiaNumber")
achemenet_number = fields.String(load_default="", data_key="achemenetNumber")
oracc_numbers = fields.List(
fields.String(), load_default=tuple(), data_key="oraccNumbers"
)
Expand Down
5 changes: 5 additions & 0 deletions ebl/fragmentarium/domain/fragment.py
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,7 @@ class ExternalNumbers:
metropolitan_number: str = ""
louvre_number: str = ""
philadelphia_number: str = ""
achemenet_number: str = ""
yale_peabody_number: str = ""
oracc_numbers: Sequence[str] = tuple()

Expand Down Expand Up @@ -266,6 +267,10 @@ def metropolitan_number(self) -> str:
def louvre_number(self) -> str:
return self._get_external_number("louvre_number")

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

@property
def philadelphia_number(self) -> str:
return self._get_external_number("philadelphia_number")
1 change: 1 addition & 0 deletions ebl/tests/factories/fragment.py
Original file line number Diff line number Diff line change
Expand Up @@ -168,6 +168,7 @@ class Meta:
louvre_number = factory.Sequence(lambda n: f"louvre-number-{n}")
philadelphia_number = factory.Sequence(lambda n: f"philadelphia-number-{n}")
yale_peabody_number = factory.Sequence(lambda n: f"yale-peabody-number-{n}")
achemenet_number = factory.Sequence(lambda n: f"achemenet-number-{n}")
oracc_numbers = factory.List(
[factory.Sequence(lambda n: f"oracc-number-{n}")], TupleFactory
)
Expand Down

0 comments on commit 05f987f

Please sign in to comment.