mirror of
https://github.com/openvk/openvk
synced 2024-11-11 01:19:53 +03:00
Support: Some fixes
:3
This commit is contained in:
parent
02e41e19b4
commit
9feea4302a
2 changed files with 6 additions and 3 deletions
|
@ -36,9 +36,12 @@ class Tickets
|
||||||
foreach($this->tickets->where(["user_id" => $userId, "deleted" => 0])->order("created DESC")->page($page, OPENVK_DEFAULT_PER_PAGE) as $ticket) yield new Ticket($ticket);
|
foreach($this->tickets->where(["user_id" => $userId, "deleted" => 0])->order("created DESC")->page($page, OPENVK_DEFAULT_PER_PAGE) as $ticket) yield new Ticket($ticket);
|
||||||
}
|
}
|
||||||
|
|
||||||
function getTicketsCountByUserId(int $userId, int $type = 0): int
|
function getTicketsCountByUserId(int $userId, int $type = NULL): int
|
||||||
{
|
{
|
||||||
return sizeof($this->tickets->where(["user_id" => $userId, "deleted" => 0, "type" => $type]));
|
if(is_null($type))
|
||||||
|
return sizeof($this->tickets->where(["user_id" => $userId, "deleted" => 0]));
|
||||||
|
else
|
||||||
|
return sizeof($this->tickets->where(["user_id" => $userId, "deleted" => 0, "type" => $type]));
|
||||||
}
|
}
|
||||||
|
|
||||||
function getRequestById(int $requestId): ?Ticket
|
function getRequestById(int $requestId): ?Ticket
|
||||||
|
|
|
@ -20,7 +20,7 @@
|
||||||
</div>
|
</div>
|
||||||
<br />
|
<br />
|
||||||
<div>
|
<div>
|
||||||
<form action="/al_comment/create/support/reply/{$id}" method="post" style="margin: 0;">
|
<form action="/al_comments/create/support/reply/{$id}" method="post" style="margin: 0;">
|
||||||
<textarea name="text" id="answer_text" style="width: 100%; resize: vertical;"></textarea>
|
<textarea name="text" id="answer_text" style="width: 100%; resize: vertical;"></textarea>
|
||||||
<br />
|
<br />
|
||||||
<input type="hidden" name="hash" value="{$csrfToken}" />
|
<input type="hidden" name="hash" value="{$csrfToken}" />
|
||||||
|
|
Loading…
Reference in a new issue