фиксы
This commit is contained in:
@@ -307,6 +307,10 @@ class Postgres(DatabaseBase, Database):
|
||||
project.deleted_at = datetime.datetime.now()
|
||||
await project.save()
|
||||
|
||||
async def check_channel_exists_in_workspace(self, channel_id: uuid.UUID, workspace_id: uuid.UUID) -> bool:
|
||||
project = await domain.Project.get_or_none(channel_id=channel_id, workspace_id=workspace_id)
|
||||
return project is not None
|
||||
|
||||
async def get_active_purchase(self, project_id: uuid.UUID, creative_id: uuid.UUID) -> domain.Purchase | None:
|
||||
return await domain.Purchase.get_or_none(
|
||||
project_id=project_id, creative_id=creative_id, status=domain.PurchaseStatus.ACTIVE
|
||||
|
||||
Reference in New Issue
Block a user