mirror of
https://github.com/kuaifan/dootask.git
synced 2026-03-17 19:23:26 +00:00
离线时更新会员最后在线时间
This commit is contained in:
parent
02b2e8cffb
commit
8110930458
@ -211,6 +211,12 @@ class WebSocketService implements WebSocketHandlerInterface
|
|||||||
/** @var WebSocket $item */
|
/** @var WebSocket $item */
|
||||||
foreach ($list as $item) {
|
foreach ($list as $item) {
|
||||||
$item->delete();
|
$item->delete();
|
||||||
|
if ($item->userid) {
|
||||||
|
// 离线时更新会员最后在线时间
|
||||||
|
User::whereUserid($item->userid)->update([
|
||||||
|
'line_at' => Carbon::now()
|
||||||
|
]);
|
||||||
|
}
|
||||||
if ($item->path && str_starts_with($item->path, "/single/file/")) {
|
if ($item->path && str_starts_with($item->path, "/single/file/")) {
|
||||||
$array[$item->path] = $item->path;
|
$array[$item->path] = $item->path;
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user