This commit is contained in:
王金磊
2023-04-07 16:46:21 +08:00
parent 7b473ffa5c
commit 996c082863
3 changed files with 12 additions and 7 deletions

View File

@@ -1428,11 +1428,14 @@ class Journal extends Controller
if (!$rule->check($data)) {
return jsonError($rule->getError());
}
$journals[] = 0;
if($data['journal_id'] != 22){
$journals[] = 0;
}
if ($data['journal_id'] != 0) {
$journals[] = $data['journal_id'];
}
$list = $this->journal_for_author->where('journal_id', 'in', $journals)->where('pid', 0)->where('jfa_state', 0)->order("sort desc")->select();
// $list = $this->journal_for_author->where('journal_id', 'in', $journals)->where('pid', 0)->where('jfa_state', 0)->order("sort desc")->select();
$list = $this->journal_for_author->where('pid', 0)->where('jfa_state', 0)->order("sort desc")->select();
foreach ($list as $k => $v) {
$cache_list = $this->journal_for_author->where('journal_id', 'in', $journals)->where('pid', $v['jfa_id'])->where('jfa_state', 0)->order("sort desc")->select();
foreach ($cache_list as $key => $val) {