Skip to content

Commit

Permalink
Include kind in edition response model
Browse files Browse the repository at this point in the history
  • Loading branch information
jonathansick committed May 21, 2024
1 parent 92d6bf7 commit 917199f
Showing 1 changed file with 11 additions and 2 deletions.
13 changes: 11 additions & 2 deletions keeper/v2api/_models.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,13 @@
if TYPE_CHECKING:
import celery

from keeper.models import Build, Edition, Organization, Product
from keeper.models import (
Build,
Edition,
EditionKind,
Organization,
Product,
)


__all__ = [
Expand Down Expand Up @@ -119,7 +125,6 @@ def from_organization(cls, org: Organization) -> OrganizationResponse:


class LayoutEnum(str, Enum):

subdomain = "subdomain"

path = "path"
Expand Down Expand Up @@ -576,6 +581,9 @@ class EditionResponse(BaseModel):
mode: str
"""The edition tracking mode."""

kind: EditionKind
"""The edition kind."""

@classmethod
def from_edition(
cls,
Expand Down Expand Up @@ -609,6 +617,7 @@ def from_edition(
"date_rebuilt": edition.date_rebuilt,
"date_ended": edition.date_ended,
"mode": edition.mode_name,
"kind": edition.kind,
"tracked_ref": tracked_ref,
"pending_rebuild": edition.pending_rebuild,
"surrogate_key": edition.surrogate_key,
Expand Down

0 comments on commit 917199f

Please sign in to comment.