Merge branch 'dev' of ssh://git.bgbg.live:18150/root/SEONexus into dev

This commit is contained in:
make
2025-05-05 13:59:52 +08:00
2 changed files with 31 additions and 7 deletions

View File

@@ -1,22 +1,22 @@
<pre> <pre>
<!-- {video:ranklist count="10" sort_type="total" v_status="wanjie" d_key="d_key" d_val="video" cache_life="1000" diff_key="fdasfads"} {video:ranklist count="10" sort_type="total" v_status="wanjie" d_key="d_key" d_val="video" cache_life="1000" diff_key="fdasfads"}
<li> <li>
章节名称: {$video.v_name} 章节名称: {$video.v_name}
章节序号: {$video.v_category} 章节序号: {$video.v_category}
</li> </li>
{/video:ranklist} --> {/video:ranklist}
{video:pager page="1" limit="10" d_key="d_key" d_val="video" cache_life="1000" button_num="3" v_category_en="动作片" v_status="wanjie" sort_type="update" p_val="page_data" func="generateVideoPager"} <!-- {video:pager page="1" limit="10" d_key="d_key" d_val="video" cache_life="1000" button_num="3" v_category_en="动作片" v_status="wanjie" sort_type="update" p_val="page_data" func="generateVideoPager"}
<li> <li>
Index: {$d_key} Index: {$d_key}
章节名称: {$video.v_name} 章节名称: {$video.v_name}
章节序号: {$video.v_category} 章节序号: {$video.v_category}
</li> </li>
{/video:pager} {/video:pager} -->
<!-- {php}var_dump($page_data);{/php} --> <!-- {php}var_dump($page_data);{/php} -->
<!-- <!--

View File

@@ -23,6 +23,7 @@ class Video extends TagLib
'categorytype' => ['attr' => 'category_type,d_key,d_val,v_sex'], 'categorytype' => ['attr' => 'category_type,d_key,d_val,v_sex'],
'ranklist' => ['attr' => 'count,sort_type,v_status,v_category_en,v_parent_category_en,diff_key,cache_life,d_key,d_val', 'close' => 1], 'ranklist' => ['attr' => 'count,sort_type,v_status,v_category_en,v_parent_category_en,diff_key,cache_life,d_key,d_val', 'close' => 1],
'ranklistexp' => ['attr' => 'count,sort_type,v_status,v_category_en,v_parent_category_en,diff_key,cache_life,d_key,d_val,export_name', 'close' => 0],
]; ];
private function customBuildVar($mixedArgs) private function customBuildVar($mixedArgs)
@@ -34,6 +35,19 @@ class Video extends TagLib
} }
} }
/**
* tagRankListExp
*
* @param array $tag
* @param string $content
* @return void
*/
public function tagRankListExp($tag, $content)
{
return $this->tagRankList($tag, $content);
}
/** /**
* tagRankList * tagRankList
* *
@@ -252,6 +266,7 @@ EOT;
$v_lang_en = $tag['v_lang_en'] ?? "all"; $v_lang_en = $tag['v_lang_en'] ?? "all";
$v_area_en = $tag['v_area_en'] ?? "all"; $v_area_en = $tag['v_area_en'] ?? "all";
$v_year = $tag['v_year'] ?? "all"; $v_year = $tag['v_year'] ?? "all";
$export_name = $tag['export_name'] ?? '';
$v_category = $this->customBuildVar($v_category); $v_category = $this->customBuildVar($v_category);
$sort_type = $this->customBuildVar($sort_type); $sort_type = $this->customBuildVar($sort_type);
@@ -280,7 +295,10 @@ EOT;
'diff_key' => {$diff_key}, 'diff_key' => {$diff_key},
'cache_life' => {$cache_life} 'cache_life' => {$cache_life}
]); ]);
EOT;
if (empty($export_name)) {
$strParse .= <<<EOT
if (!empty(\${$arrDataName}) && is_array(\${$arrDataName})): if (!empty(\${$arrDataName}) && is_array(\${$arrDataName})):
?> ?>
@@ -293,6 +311,12 @@ EOT;
<?php endforeach; ?> <?php endforeach; ?>
<?php endif; ?> <?php endif; ?>
EOT; EOT;
} else {
$strParse .= <<<EOT
\${$export_name} = \${$arrDataName};
?>
EOT;
}
return $strParse; return $strParse;
} }