feat(fulfillment): 支持选号优先级、三皮肤联合资格捆绑与同角色共享租约
This commit is contained in:
@@ -1785,6 +1785,43 @@ class PlatformFulfillmentCustomerProfileUpdate(BaseModel):
|
||||
reopen_binding: bool = True
|
||||
|
||||
|
||||
class PlatformFulfillmentBundleRule(BaseModel):
|
||||
id: str = Field(default="", max_length=64)
|
||||
name: str = Field(default="", max_length=128)
|
||||
enabled: bool = True
|
||||
mode: str = Field(default="require_all", pattern="^(require_all|prefer_all)$")
|
||||
commodity_ids: list[str] = Field(
|
||||
default_factory=list,
|
||||
alias="commodityIds",
|
||||
max_length=30,
|
||||
)
|
||||
|
||||
model_config = {"populate_by_name": True}
|
||||
|
||||
|
||||
class PlatformFulfillmentAllocationPolicy(BaseModel):
|
||||
same_role_reuse_enabled: bool = Field(
|
||||
default=True,
|
||||
alias="sameRoleReuseEnabled",
|
||||
)
|
||||
preserve_bundle_pool: bool = Field(
|
||||
default=True,
|
||||
alias="preserveBundlePool",
|
||||
)
|
||||
priority_order: list[str] = Field(
|
||||
default_factory=list,
|
||||
alias="priorityOrder",
|
||||
max_length=16,
|
||||
)
|
||||
bundle_rules: list[PlatformFulfillmentBundleRule] = Field(
|
||||
default_factory=list,
|
||||
alias="bundleRules",
|
||||
max_length=20,
|
||||
)
|
||||
|
||||
model_config = {"populate_by_name": True}
|
||||
|
||||
|
||||
class PlatformFulfillmentSettingsUpdate(BaseModel):
|
||||
lease_duration_minutes: int | None = Field(..., ge=1, le=525600)
|
||||
completed_release_delay_minutes: int | None = Field(
|
||||
@@ -1808,6 +1845,11 @@ class PlatformFulfillmentSettingsUpdate(BaseModel):
|
||||
le=525600,
|
||||
)
|
||||
order_match_started_at: datetime | None = None
|
||||
allocation_policy: PlatformFulfillmentAllocationPolicy | dict[str, Any] | None = (
|
||||
Field(default=None, alias="allocationPolicy")
|
||||
)
|
||||
|
||||
model_config = {"populate_by_name": True}
|
||||
|
||||
|
||||
class PlatformFulfillmentCustomerSessionRequest(BaseModel):
|
||||
|
||||
Reference in New Issue
Block a user