From 01f15a72e0974dccf8abb318eb2d0e85deb2b155 Mon Sep 17 00:00:00 2001 From: gzydong <837215079@qq.com> Date: Tue, 6 Jul 2021 23:44:17 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96=E4=BB=A3=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/Service/ContactsService.php | 39 ++++----------------------------- 1 file changed, 4 insertions(+), 35 deletions(-) diff --git a/app/Service/ContactsService.php b/app/Service/ContactsService.php index ed9a76e..e51073c 100644 --- a/app/Service/ContactsService.php +++ b/app/Service/ContactsService.php @@ -27,29 +27,6 @@ class ContactsService extends BaseService { use PagingTrait; - /** - * 获取联系人列表 - * - * @param int $user_id 用户ID - * @return array - */ - public function getContacts(int $user_id): array - { - - - $prefix = config('databases.default.prefix'); - $sql = << $friend_id) { - [$user_id, $friend_id] = [$friend_id, $user_id]; - $data['user2_remark'] = $remarks; - } else { - $data['user1_remark'] = $remarks; - } - - return (bool)UsersFriend::where('user1', $user_id)->where('user2', $friend_id)->update($data); + return (bool)UsersFriend::where('user_id', $user_id)->where('friend_id', $friend_id)->update(['remark' => $remark]); } /**