修改查询教师错复
This commit is contained in:
1 parent
f375328cb6
commit
a1e6dc24dc
8 files changed
+16
-9
No files matched your search
@@ -364,6 +364,13 @@ class Index extends Base
|
||||
// 如果有数据则查询教师信息
|
||||
$list = Teacher::field('id,xingming,danwei,shengri,sex')
|
||||
->whereOr('xingming|quanpin|shoupin','like','%'.$str.'%')
|
||||
->with(
|
||||
[
|
||||
'jsDanwei'=>function($query){
|
||||
$query->field('id,jiancheng');
|
||||
},
|
||||
]
|
||||
)
|
||||
->append(['age'])
|
||||
->all();
|
||||
return json($list);
|
||||
|
||||
Reference in new issue
Block a user