From 7767f2fbf9e8602fc9750773b80c4f5a5a041a23 Mon Sep 17 00:00:00 2001 From: filesite Date: Sat, 25 Jan 2025 08:18:15 +0800 Subject: [PATCH] support mp3 in subcate --- themes/beauty/controller/ListController.php | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/themes/beauty/controller/ListController.php b/themes/beauty/controller/ListController.php index 7959b66..9d73377 100644 --- a/themes/beauty/controller/ListController.php +++ b/themes/beauty/controller/ListController.php @@ -193,6 +193,13 @@ Class ListController extends Controller { //当前目录数据 $subcate = !empty($scanResults[$cateId]) ? $scanResults[$cateId] : array(); + //支持子目录下的MP3音乐优先 + $mp3FileInSubcate = $scanner->getDefaultFile('mp3'); + if (!empty($mp3FileInSubcate)) { + $mp3File = $mp3FileInSubcate; + } + + //翻页支持 $page = $this->get('page', 1); $pageSize = $this->get('limit', FSC::$app['config']['default_page_size']);