From 124a2b6b0f47529a193ed9d16bc70e2168c67aaa Mon Sep 17 00:00:00 2001 From: elf <360197197@qq.com> Date: Tue, 12 Oct 2021 14:42:25 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Application/Admin/Common/extend.php | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/Application/Admin/Common/extend.php b/Application/Admin/Common/extend.php index 325b5191c..65329acd8 100644 --- a/Application/Admin/Common/extend.php +++ b/Application/Admin/Common/extend.php @@ -3255,4 +3255,14 @@ function array_repeat($array,$keyid="id",$desc=false) $c = array_rsort($c,true); } return $c; +} + +function getShiftingMends(array $userIds = null) +{ + $map = ['status' => 0]; + if (!is_null($userIds)) { + $map['user_id'] = ['in', $userIds]; + } + $mends = M('mend', 'tab_')->field(['id', 'user_id'])->where($map)->select(); + return index_by_column('user_id', $mends); } \ No newline at end of file