app首页视频封面,上传监控视频封面
This commit is contained in:
parent
b04c038bd3
commit
19e6a34aab
|
@ -51,7 +51,7 @@ class IndexController extends BaseApiController
|
||||||
$data['device_id'] = $device['id'];
|
$data['device_id'] = $device['id'];
|
||||||
// 监控视频封面
|
// 监控视频封面
|
||||||
$file = File::where('cid', $device['id'])->order('id', 'desc')->findOrEmpty();
|
$file = File::where('cid', $device['id'])->order('id', 'desc')->findOrEmpty();
|
||||||
$data['video_cover'] = isset($file['url'])? env('project.project_url').'/'.$file['url']: '';
|
$data['video_cover'] = isset($file['uri'])? env('project.project_url').'/'.$file['uri']: '';
|
||||||
$landCollection = LandCollection::where('land_id',$params['land_id'])->order('id desc')->findOrEmpty();
|
$landCollection = LandCollection::where('land_id',$params['land_id'])->order('id desc')->findOrEmpty();
|
||||||
if($landCollection->isEmpty()){
|
if($landCollection->isEmpty()){
|
||||||
$data['monitor'] = [];
|
$data['monitor'] = [];
|
||||||
|
|
Loading…
Reference in New Issue