mirror of
https://github.com/System-End/nephthys.git
synced 2026-04-19 18:35:14 +00:00
give assigned user resolve credit
This commit is contained in:
parent
486a3e1489
commit
468aa9cb1d
1 changed files with 7 additions and 0 deletions
|
|
@ -31,6 +31,13 @@ async def resolve(ts: str, resolver: str, client: AsyncWebClient):
|
|||
if not ticket:
|
||||
return
|
||||
|
||||
if not resolving_user.helper and ticket.assignedTo:
|
||||
new_resolving_user = await env.db.user.find_unique(
|
||||
where={"id": ticket.assignedTo.id}
|
||||
)
|
||||
if new_resolving_user:
|
||||
resolving_user = new_resolving_user
|
||||
|
||||
now = datetime.now()
|
||||
|
||||
tkt = await env.db.ticket.update(
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue