This commit is contained in:
knowpia
2022-09-16 10:28:39 +08:00
parent 18370dbfc7
commit 2ea7b0307d

View File

@@ -69,10 +69,6 @@ class Donation
if(!empty($list)){ if(!empty($list)){
$appUser = getAllUsersMessage($list,"user_id","id,nickname"); $appUser = getAllUsersMessage($list,"user_id","id,nickname");
$studentUser = $this->getStudents($list); $studentUser = $this->getStudents($list);
print_r($appUser);
print_r($studentUser);
foreach ($list as $key => $vo) { foreach ($list as $key => $vo) {
$result['lastIndex'] = $vo['id']; $result['lastIndex'] = $vo['id'];
$result["list"][] = [ $result["list"][] = [
@@ -99,8 +95,7 @@ class Donation
} }
$StudentIds = array_unique($StudentIds); $StudentIds = array_unique($StudentIds);
$getAllStudentsMessage = []; $getAllStudentsMessage = [];
$UserLists = Db::name("student")->where("id", "IN",$StudentIds)->field("nickname")->select()->toArray(); $UserLists = Db::name("student")->where("id", "IN",$StudentIds)->field("id,nickname")->select()->toArray();
print_r($UserLists);
foreach ($UserLists as $vo) { foreach ($UserLists as $vo) {
$getAllStudentsMessage[$vo['id']] = $vo; $getAllStudentsMessage[$vo['id']] = $vo;
} }